Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Relief Terrain Pack (RTP) v3 on AssetStore

Discussion in 'Assets and Asset Store' started by tomaszek, Oct 22, 2013.

  1. bac9-flcl

    bac9-flcl

    Joined:
    Dec 5, 2012
    Posts:
    829
    @tomaszek

    Thanks for the info! Yeah, I can understand that and I'll try to implement those myself - I was mostly asking to confirm whether those ideas are possible to implement at all, from what you're seeing as the developer of the shader. Good to hear they seem to be.

    Can you recommend a way to somehow save the customized code so that it won't be overwritten on each LOD manager change (like fog baking etc.)? Or LOD manager isn't assembling the shaders from scratch every time but editing and saving existing files, therefore those changes can stay unaffected (I'm getting that impression from the "tweaking features manually" section of the docs as there is no mention of those settings being reset).
     
  2. tomaszek

    tomaszek

    Joined:
    Jun 18, 2009
    Posts:
    3,862
    LOD manager enables /disables #define keywords in files (beginners might have problems with that) and eventually enables some passes. So - feel free to dig into RTP_Base.cginc

    Tom
     
  3. bmccall1

    bmccall1

    Joined:
    Jul 28, 2013
    Posts:
    120
    Tom, I have another question. On my newest terrain, Im doing forward rendering and linear lighting, and I am getting this weird flickering effect in some areas on my terrain until the camera settles.

    Essentially if i move a few steps forward, and stop, you can see the shadows flicker rapidly. Then after a few seconds it settles and stops. I have a web player that shows the effect. Any idea what could be causing this?
     
  4. tomaszek

    tomaszek

    Joined:
    Jun 18, 2009
    Posts:
    3,862
    Could you give me an access to your web player where it occurs ?

    Tom
     
  5. bmccall1

    bmccall1

    Joined:
    Jul 28, 2013
    Posts:
    120
    Hi, wow fast response!

    http://baffledmedia.com/unity/alpha1.02/

    EDIT: Since you're looking at it, one thing I've noticed is on my radeon 6970 i only get about 40 fps on that terrain which is a bit lower than I'd like. I've turned the camera range down to 300 and moved pixel error to 18 to get it to this point, but its still a little low.

    Do you think that smoothing out some of the terrain would help lower the polys and increase the fps or have i dont something else really bad, and thats part of the flickering as well?
     
    Last edited: Jun 5, 2014
  6. tomaszek

    tomaszek

    Joined:
    Jun 18, 2009
    Posts:
    3,862
    6970 is quite powerfull GPU, I get higher framerates on my nVidia GT240. Anyway RTP shouldn't hit GPU that much. Reason is probably different thing (maybe use profiler or try todisable something on your scene). Wht's you feature list enabled in RTP LOD manager ?

    What set of postprocess do you use, because it looks like kind of buggy SSAO ?

    Tom
     
  7. bmccall1

    bmccall1

    Joined:
    Jul 28, 2013
    Posts:
    120
    I will run the profiler. I did turn off most of the complex shaders in RTP and the SSAO is console 3 fXAA i believe and disabling it didn't help.

    The terrain is like 1.5 million pixels even with pixel error turned to 18 so I wonder if that's a problem. Perhaps my camera isn't doing a good enough job at culling?

    Any idea on the flicker?
     
  8. tomaszek

    tomaszek

    Joined:
    Jun 18, 2009
    Posts:
    3,862
    1.5M pixels on pixel error 18 means probably you've got very hi-res heightmaps or very many terrain objects. Anyway for Unity terrains it's big number causing quite a lot drawcalls. That hurts CPU. With many terrain objects on the scene consider not using "Use U4 materials" inLOD manager. About flickering - I've got no idea. Can you check my example scenes included if there is similar effect ? If not then you could try to narrow and locate potential culprit.

    Tom
     
  9. bac9-flcl

    bac9-flcl

    Joined:
    Dec 5, 2012
    Posts:
    829
    Small bug I have noticed: global wetness is not being used to update water rendering when you call Refresh() on the settings class, but is updated if you call RefreshAll (). I'm not sure if this is new behavior, as I recall it working in Unity 4.3, but I guess it's worth checking out. Wetness slider itself is updated properly, but without calling RefreshAll() it only takes effect when you touch it yourself through the inspector.

    P.S.: By the way, I may be misunderstanding something, but is there a reason why ReliefTerrain references aren't being cached by the ReliefTerrainGlobalSettingsHolder? I'm talking about this particular line in RefreshAll():

    ReliefTerrain[] rts=GameObject.FindObjectsOfType(typeof(ReliefTerrain)) as ReliefTerrain[];
    (aside from it, docs recommend to use Refresh without ReliefTerrain reference in the arguments, so similar search probably occurs there)

    I would guess it's not very healthy thing to call on every weather system update. :)
     
  10. khos85

    khos85

    Joined:
    Jul 21, 2013
    Posts:
    541
    Hi Tom,
    Many thanks for your reply, here is the link to the image
    Hopefully you can see this?
    The part where you write "After you've got terrain objects on your scene with proper number of layers you can assign RTP by hand to each terrain and then tweak parameters.", maybe you can tell from the screenshot if the layers are ok?
    I know there is no magic button :), I just have play with it more and get to know it I guess..
    thanks for any help given.
     

    Attached Files:

  11. omgeric

    omgeric

    Joined:
    Aug 18, 2013
    Posts:
    18
    I've unchecked "sharpen heightblend edges", is there a way to have smoother transitions like when you don't use heightmaps? I'm looking in the code and I'm playing around with stuff around line 1953 of RTPBase but I'm not getting smoother transitions.
     

    Attached Files:

  12. bmccall1

    bmccall1

    Joined:
    Jul 28, 2013
    Posts:
    120
    I got rtp3.1c and for some reason, all my terrain brushes are square and seemingly huge. I cannot select any of the other hand brushes to paint terrain with and they are many times larger than they should be. Did I do something wrong?
     
  13. VicToMeyeZR

    VicToMeyeZR

    Joined:
    Jun 3, 2012
    Posts:
    427
    I think its a Unity bug. Save your scene, and close down/restart unity. The brushes do that to me sometimes too, you just have to play with the brush selection and size until it comes back
     
  14. tomaszek

    tomaszek

    Joined:
    Jun 18, 2009
    Posts:
    3,862
    From your screenshot I see you've got only 1 layer defined for your terrain. For RTP use 4 or 8. Recompile shaders for terrain and your platform. In Terrain Composer I see some random textures (splat control, normalmaps, combined, etc...) defined and textures. You'd need probably to follow Terrain Composer guidelines. I believe there is kind of tutorial describing TC&RTP.

    I can't see if you've got RTP applied to terrain objects. So I can't tell what's your LOD manager settings and how, at least roughly is your ReliefTerrain scrtipt state for given terrain object. Maybe try to ask on TC forum or give me more information.

    Tom
     
  15. tomaszek

    tomaszek

    Joined:
    Jun 18, 2009
    Posts:
    3,862
    This might happen when you use materials on your terrains. Generally Refresh() works for current terrain tile, while RefreshAll() iterate across all ReliefTerrain instantces. This is maybe not much optimal, but I assume even weather doesn't change that quick and aburpt. Chnging this once a few seconds should be enough. I'm wondering why it doesn't work globally for you. In RTP3.1c in Refresh(...) function inside ReliefTerrainGlobalSettingsHolder.cs I'm doing both calls - setting material (if is present) and global like this:

    Code (csharp):
    1. SetShaderParam("TERRAIN_GlobalWetness", TERRAIN_GlobalWetness);
    2. Shader.SetGlobalFloat("TERRAIN_GlobalWetness", TERRAIN_GlobalWetness);
    I'm not sure if first call doesn't break something. You could try to caomment call to material and check if you're able to change global wetness globally. As you see (and all these params are listed, grouped and briefly commented in my docs) you can change it yourself without necessity to call Refresh functions. Using Shader.SetGlobal command you (in case of materials that need to be updated) - using materialInstance.Set... That will ensure changes are applied on features needed only.

    Tom[/code]
     
  16. tomaszek

    tomaszek

    Joined:
    Jun 18, 2009
    Posts:
    3,862
    In RTP3.1c this starts with line 1983, so maybe you should upgrade ? I fixed heightblend issues comparing to RTP3.0.
    On your screenshot it looks like heightmaps doesn't reflect detail texture. I would suppose that little rocks and pebbles that are present on grey texture should pop up over leaves texture but I see rather something like "holes". Anyway, in RTP_Base.cginc (and RTP_AddBase.cginc) there is a part of code that calculates heightblend:

    Code (csharp):
    1. float4 splat_control1_mid=splat_control1*splat_control1;
    2. splat_control1_mid/=dot(splat_control1_mid,1);
    3. float4 splat_control1_close=splat_control1_mid*splat_control1_mid;
    If you remove multiplications (leaving only splat_control1_mid=splat_control1 splat_control1_close=splat_control1) you'll have as smooth transition as possible. It wont be "compressed" by these multiplications. But still - coverage will be multiplied by heightmap values and normalized. This is case of 4 layers rendered in a pass. In 8 layers mode proper part of code is placed a few lines below and engages splat_control1 and splat_control2 variables that are combined. Analysis that part of code should be difficult.

    Tom
     
  17. horse

    horse

    Joined:
    Jun 17, 2009
    Posts:
    19
    Hi Tom,
    I used your shader prior to updating unity and the RTP package and i was getting some good results.
    Tonight, i can not seem to get anything to work. Even the example scene in RTP appears to be using the basic unity shader without any texture details at all. the flowing water is working, but everything else is blurry and terrible. It seems i have hit a massive road block. Hoping you can shed some light on whats happening?
     
  18. bac9-flcl

    bac9-flcl

    Joined:
    Dec 5, 2012
    Posts:
    829
    If you have imported an update, all your shaders will be reset to their initial state. Apply LOD manager settings again to create shaders with features you need.
     
  19. khos85

    khos85

    Joined:
    Jul 21, 2013
    Posts:
    541

    In the image I have already uploaded in the previous post you'll see that I have "layers" set. Maybe this is where I am confused with what you mean by "layers", where are these supposed to be defined?

    In the screenshot I already gave you'll see on the terraincomposer window > Root > Layer0 Splats(4) ... I have this x4 so Layer0 , Layer01, Layer02, Layer3, each with 4 splats.. I am guessing this is not the correct place for where you refer to as layer?

    So where should I define layers for the terrains that I intend to use with RTP? Could you point me in the right direction please.

    Many thanks,
    Kim
     
  20. tomaszek

    tomaszek

    Joined:
    Jun 18, 2009
    Posts:
    3,862
    @khos85, sorry you're asking wrong guy :) I'd help you but I don't know much about Terrain Composer. When ReliefTerrain script (RTP component) is applied your terrain object should have 4 layers (or 8) already dfined. These are regular terrain layers like in Unity terrain engine. Have you dealt with Unity terrains before ? RTP uses these layers but uses dufferent, more advaced shader.

    Tom
     
  21. bmccall1

    bmccall1

    Joined:
    Jul 28, 2013
    Posts:
    120

    Khos - Watch the video :



    He basically shows you that when you define a terrain, define the layers by just adding 4 textures, and you can put whatever you want to in there it doesn't matter. You do this before you import the height map and then before you add the relief terrain engine to the scene.

    You probably don't have to define the layers prior to defining the height map but i've had less problems with it.
     
  22. Nitecon

    Nitecon

    Joined:
    Jun 6, 2014
    Posts:
    3
    Thomas just a quick question and request...

    Although RTP does support substance materials it doesn't allow assigning substances directly as splat textures. It's something that I was very much hoping for.

    Do you have any plan to update the ability to use this directly similar to the Substance Terrain Tool? Found here: https://www.assetstore.unity3d.com/en/#!/content/2179

    If that could be implemented or is in the works it would be hands down the most amazing tool available. The reason why I ask for that is that it would allow modification of the terrain material on the fly. If rocks/grass/ice etc are slightly too bland you can alter your substance and it reflects in real time.

    One additional note for those that use substances to get their textures....
    When I take my substance and export the diffuse/height/normal to be used in RTP the specular color is way too bright and you just need to change that color to a dark grey etc.

    If you would like to chat regarding this please let me know.
     
  23. khos85

    khos85

    Joined:
    Jul 21, 2013
    Posts:
    541

    Thanks for the info, I have already watched the video (even before I purchased rtp) and I can use rtp on it's own with the standard unity terrain.. to clarify, my problem lies when I want to use RTP with other tools like terraincomposer/worldcomposer.. in my game the terrains that terraincomposer/worldcomposer generated work perfectly, until I add RTP. Then the satellite image goes away that is assigned to the particular terrain and the terrain turns grey.
    Tom advises that he that RTP needs 4 layers, well I have that..not initially but added later,but anyway maybe that is where the issue lies? I have to add the 5 layers/textures on each terrain (that could take a while if I have 100 terrains).

    Tom, I have some experience of working with terrains, proof in the pudding is by looking at a youtube vid of my paraglider game (
    ) , I'm no expert but I do think I know my way around terrains..my wish is to improve the ground detail on this game.
    I'll ask Nathanial for advise , see how that goes.
    Thanks all your help so far, much appreciated.
     
  24. snowcult

    snowcult

    Joined:
    Feb 6, 2014
    Posts:
    295
    Had everything perfect, realised I missed an update, updated > now everything is reset and broken. Goes either black or looking like this: http://i.imgur.com/gbuhU3A.jpg :/

    Even removing LOD manager and the RTP script from my terrain (as well as changing material) gives me this:

    http://i.imgur.com/CoJylTh.png

    O_O
     
  25. tomaszek

    tomaszek

    Joined:
    Jun 18, 2009
    Posts:
    3,862
    @Nitecon,
    Yes I'm thinking about it for next updates, but can't promise any timeframe for realization. Substances could be applied to terrain shader as they are because on script level they are of ProceduralTexture type which simply inherits from Texture. In case of RTP it's more complex because I don't use texture as they are, but prepared one. Color texture when we don't use atlases is ready for use, but normalmaps and heightmaps are combined to save texture samplers. If this option is so important, you could try to implement it yourself. Basically it would do what my editor scripts do when you click "Get" button below texture. It grabs texture2D from substance and merge it in pair (normals) or quads(heights).

    @khos85,
    I make no assumptions on your skills. Sorry if you feel like that. If you've got 100 terrains that's pretty massive.
    1. First - turn off using materials in LOD manager. That will ensure our CPU load will not kill the performance.
    2. Then recompile shaders. If you need really 5 layers, you should round to next value - 8 layers. Using 5 or 8 doesn't matter in terms of performance and you waste 3 slots. Then decide wheter you'd like to render it in 2 passes or one pass that will need atlasing (8 layers in first pass mode in LOD manager).
    3. Setup your environment in WC/TC. Make sure that resultant terains has 8 layers. I can't tell which kind of shader WC uses, but we need to make sure no other terrain shaders are present in the project (that's important because we don't use materials !).

    That's it - we're ready to select all terrains and apply ReliefTerrain.cs script to all of them. That can be done manually. Then you need to tweak all params for one terrain and this will seen (applied) by other terrains. Eventually use Settings/main/Refresh All button.
    The only problem is then this satellite image you can get from WC is very helpful and should be used as global colormap in RTP. Assigning it manually for all terrain tiles (in Global maps/ global colormap) is lengthy and I know that TC can do it automatically using its magic <RTP> button, although I also no expert here and you should ask Nathaniel (eagle555) about it. The same for global normalmaps that can be assigned on every terrain object separately to allow you reduce polycount (lifting higher pixel error) while being able to hold surface details at distance. It might be not needed when lighting is baked into satellite image (global colormap).

    @ShinfoK,
    Your terrain uses default (classic) shading. The question is - update was made from RTP3.0 to 3.1c ? It might take some time to cleanup things as 3.1 is in some places pretty different and I warned about it in my docs. If you updated from 3.1 to 3.1c you simply need to recompile shaders in LOD manager with the same feature set you had before. Then refreshing scene in settings/Main. It should be back to the previous look. Anyway - recompiling shaders is what's needed after any update (shaders comes in default / raw state in package).

    ATB, Tom
     
    Last edited: Jun 7, 2014
  26. snowcult

    snowcult

    Joined:
    Feb 6, 2014
    Posts:
    295
    Didn't work at all. Reverting back.

    *sigh* Everything was perfect before. I was stupid enough to go along and reset everything because it was all black and I couldn't figure out why (after searching this thread and non of the answers working)... so, it looks like I'm stuck. I've reverted back and still only seeing the colourmap (I guess? Only colours on the terrain, no textures).

    Edit: forgot to compile for dx11. Yeah reverting back to 3.1 and everything is working as I want it again (after a lot of messing around)... c (for me) is a dud.
     
    Last edited: Jun 7, 2014
  27. snowcult

    snowcult

    Joined:
    Feb 6, 2014
    Posts:
    295
    Okay, so back because I want this to actually work. Upgrading from 3.0

    So the upgrade, I recompile my shaders. Textures are black. Change LOD to Classic, and it's how my terrain looks without RTP. All other LOD creates black terrain. What are the steps from here? That video "first steps" is not helping.

    This (tree billboard) has since appeared too... :/
    http://i.imgur.com/xd5FfFR.png

    Ugh, this thing is just so bloody confusing.
     
    Last edited: Jun 7, 2014
  28. tomaszek

    tomaszek

    Joined:
    Jun 18, 2009
    Posts:
    3,862
    If you initially upgraded from 3.0 to 3.1 it's not that straightforward as 3.1 is simply almost new product due to massive modifications made. So - as I described in docs - upgrade is possible but first you need to remove 3.0 (and remove ReliefTerrain scripts from your terrains and remove LOD manager from your scene). Then install 3.1c. Recompile for dx11. The reason things might be black is that 3.1 introduces new params like brightness set globally and per layer. If these params are undefined (not defined in 3.0) they might be zeroed after you updated to 3.1 w/o cleaning things first. "Reset to defaults" buttons (per layer and in settings) can help then (or tweak brightness params manually), but I recommend to install 3.1c on the "clean" project where you don't have RTP at all.

    Trees are not handled by RTP. I saw such problems before but it's not related to RTP. It's due to incorrect drawing order. Underlying content in the background must be rendered before trees, but can't tell why it's not. RTP shaders have drawing queue order that's set before opaque geometry so it is supposed to be rendered before transparent billboards.

    Tom
     
    snowcult likes this.
  29. teaMate_

    teaMate_

    Joined:
    Apr 15, 2014
    Posts:
    7
    Hi Tom,

    i've updated RTP to 3.1c to solve compatibility issues with Unity 4.5 but also to try to resolve the "alt-tabbing" problem.
    I think there's a problem with the "RTPFogUpdate" script and with RefreshAll() in particular.
    Looking at the Profiler there's a big load on the CPU coming from RTPFogUpdate.RefreshAll(), that's affecting the performances both in Editor Mode and Play Mode. I find it difficult to explain it, but switching between "Scene" view and "Game" view is really slow. Also focusing on a Camera or hitting Play. Basically everytime it needs to render the scene. Same thing happens after building the executable.

    Commenting everything inside the RefreshAll() method solved the problems. I assume doing this doesn't solve the "alt-tabbing" issue.
    For your interest i'm working with multiple terrains (20+). I'm willing to share more information if you need them.
     
  30. khela

    khela

    Joined:
    Oct 23, 2013
    Posts:
    8
    hi, how i can adjust specular level per layer? for example, i want my rock looks shiny but not my grass.. thanks
     
  31. GXMark

    GXMark

    Joined:
    Oct 13, 2012
    Posts:
    514
    I understand why you suggest preparing these at development time but in the game i'm making lots of combinations of different textures can be selected in the game at runtime from an inventory. I do not know which textures will be required as part of an atlas because these textures are importable (at runtime) into the game. The terrain is really dynamic at runtime thus hinders this style of MMO RPG gaming.

    To get around this issue i'm using the Skyshop terrain shader which does not do atlasing hence provides me with a solution. However, I still prefer RTP product in the main which i'd move over to if such a feature existed.
     
  32. ericcowan

    ericcowan

    Joined:
    Oct 24, 2013
    Posts:
    17
    I’ve followed the main tutorial video, and when click on engine – terrain or mesh, I lose all the textures detail. I keep thinking that maybe the tiling is off or something, but I’ve follow every word three times. As you can see in the picture, it’s a flat plane color not the pebble texture which it should be. I’m hoping I overlooked something simple. Help please. testPage.jpg
     
  33. ericcowan

    ericcowan

    Joined:
    Oct 24, 2013
    Posts:
    17

    I did over look something... DX11 then recompile.
     
  34. tomaszek

    tomaszek

    Joined:
    Jun 18, 2009
    Posts:
    3,862
    You're not forced to use atlasing. RTP can work in 4+4 mode (but then 2 passes are needed to render terrain). In regards to combined normalmaps and heightmaps. They are not difficult to prepare runtime. Normalmaps are combined in pairs (A+G channel of first layer with A+G channel of second layer willbe like AGAG=RGBA combined normalmap). You can use functions provided by RTP and use them in your game. If functions are editor only, just copy their functionalities into your own class. Heightmaps combined are RGBA or first (R), 2nd (G), 3rd (B) and 4th (A) heightmap. After you've got these combined textures ready you can set them in reliefTerrainInsance.globalSettingsHolder. In my docs I put a table with all (almost) RTP textures and params used. Then call RefreshAll() function and this should work.

    Tom
     
  35. tomaszek

    tomaszek

    Joined:
    Jun 18, 2009
    Posts:
    3,862
    Specularity is controlled by alpha channel of detail color texture. Then you can adjust its specularity using per layer settings (spec muliplier, gloss shaping and so on). It's extensively described in my docs.

    Tom
     
  36. tomaszek

    tomaszek

    Joined:
    Jun 18, 2009
    Posts:
    3,862
    What I did in RTP3.1c to make "100%" sure that alt+tabbing is solved was:
    1. introducing properties in terrain material (if used). From my tests that was real culprit of alt tabbing problem
    2. implemented OnApplicationFocus in RTPFogUpdate.cs

    Ad 1. I tested it again today and it seems that what really hurts is using materials. Previously I left only a few basic properties exposed in ReliefTerrain-FirstPass.shader which was causing about 1ms cost per terrain object. This seems to be ridiculous and I can't tell what unity do in the background when rendering terrain (Culling and it's internal mysterious Height.RenderStep3 function). When I added RTP props to shader (used with materials) it now get even worse - 2ms per terrain tile (my i3 CPU on Win XP Unity 4.5.0f6) ! So this solution for alt+tabbing is fine but can kill CPU in presence of more terrain tiles...

    Ad 2. Solution 1 is probably enough, but as alt+tabbing means we loose and regain focus I also implemented OnApplicationFocus function. This refreshes all params in all terrains and all geom blend objects present on scene. That's why it can be expensive depending on how many objects we've got. Focus refreshing issue is the problem of terrain only so maybe we could only refresh terrain tiles then. First of all - when you've got thousands game objects present in your scene my approach to get all ReliefTerrain instances and all GeomBlend instances (look at RefreshAll function in ReliefTerrainGlobalSettingsHolder.cs) is not optimal. You could cache them in array to not searching for them every time. I could do it myself in RTP, but I'm thinking what's the best moment to build such cache array ? In Start() function - yes, but in editor mode I've got no idea how to determine when you add or remove geom blend objects and terrains. Maybe some kind of separate button like "Rebuild RTP objects cache" might be solution.

    Counclusion is like this - alt+tabbing problem is solved at cost... When you'd like to improve game performance using materials you'll be forced to remove properties from ReliefTerrain-FirstPass.shader. Then solution 2 would take care about refreshing, but we still need some optimizations here.

    I would like other users thoughts over this issue also, so we could agree a practical solution that I might implement in 3.1d update.

    Tom
     
  37. snowcult

    snowcult

    Joined:
    Feb 6, 2014
    Posts:
    295
    Wracking my brain on this. I've literally got a new terrain. Imported heightmap from World Machine. Done the splat and trees/grass in Terrain Composer, and now done the RTP. Everything is great up until Terrain Composer.

    LOD Level is POM with shadows and soft shadows ticked.

    Use U4 materials ticked
    First Pass ticked
    Far Distance ticked
    d3d9 and dx11 (i'm using dx11) both ticked.
    Enable holes cut ticked
    PBL fresnel ticked
    PBL fit for deferred ticked
    8 layers in first pass ticked (tried both this, and unticked)
    Maxlod = pm
    UV blend ticked
    Global color blend multiplicative ticked
    Dynamic snow ticked
    Sharped heightblend edges ticked
    heightblend fake ao ticked.

    Annnnd... black terrain straight off the bat. This is not upgrading from 3, this is straight up 3.1c import into a new terrain.
    Terrain composer has RTP enabled (and all splats/normals/height added). The brightness is fine.

    Additionally, when terrain is selected, I get continuous console warnings now:

    Material doesn't have a texture property '_MainTex'
    UnityEditor.DockArea:OnGUI()

    I see absolutely no reason why is this isn't working for me.
     
  38. tomaszek

    tomaszek

    Joined:
    Jun 18, 2009
    Posts:
    3,862
    @ShinfoK, material warning is most often associated with problem of shader that have problems with compilation. When you select FirstPass shader in project view do you see any errors/warnings there ? Could you try this on DX9 ? And maybe try to hit "Return layer params to default" - button at the bottom of layer properties.

    I think you could just make a screenshare over skype to detect the problem quicker. You can contact me PM (please post there your order number).

    Tom
     
  39. ericcowan

    ericcowan

    Joined:
    Oct 24, 2013
    Posts:
    17
    When I turn on shadows from the directional light the terrain turns pink. Any suggestions?
     
  40. tomaszek

    tomaszek

    Joined:
    Jun 18, 2009
    Posts:
    3,862
    @ericcowan, shadows works fine for me. Could you give exact setup (Unity version, forward, deferred, linear lighting and LOD manager features enabled) ? Nobody reported such problem before. What's the platform you're working on (dx9, dx11, opengl ?)

    Tom
     
  41. teaMate_

    teaMate_

    Joined:
    Apr 15, 2014
    Posts:
    7
    Hi,

    thanks for your comprehensive reply

    I think this could be a nice solution. Even if it takes seconds/minutes to cache all the objects.

    About materials, i don't know. I can confirm that Terrain.Heightmap.RenderStep3 seems to require a lot of CPU power.
     
  42. ericcowan

    ericcowan

    Joined:
    Oct 24, 2013
    Posts:
    17
    Thank you for the response Tom. Unity version 4.5.0f6, looks like an error message I didn’t notice.

    Shader error in 'Relief Pack/ReliefTerrain-FarOnly': failed to open source file: 'RTP_Base.cginc' at line 54.

    I don’t see any settings for forward, deferred, or linear lighting. I’m running Window 7 64 bit and DX11. lightSettings.jpg quatilySettings.jpg
     
  43. tomaszek

    tomaszek

    Joined:
    Jun 18, 2009
    Posts:
    3,862
    @ericcowan,

    Try to change problematic line:

    Code (csharp):
    1. #include "RTP_Base.cginc"
    with this:

    Code (csharp):
    1. #include "./RTP_Base.cginc"
    or this:

    Code (csharp):
    1. #include "Assets/ReliefPack/Shaders/ReliefTerrain/RTP_Base.cginc"
    U4.5 has rebuilt shader compilation routines and resolves paths different way. However I checked RTP3.1c on my side (U4.5.0.f6 on WinXP, dx9, opengl) this might be related to DX11 maybe. I need to check this on my DX11 laptop.

    If similar error appear on another RTP shader you can try to fix it the same way changing include path.

    Tom
     
  44. Robsy128

    Robsy128

    Joined:
    Aug 8, 2013
    Posts:
    35
    Hi Tom,

    I've just made a normal map for one of my textures, but whenever I click and drag it into the Layers section, the inspector suddenly flips to a completely different normal map which I don't want. An error message also comes up in the console saying: "Normal textures pair 2,3 should have the same size".

    The full console details are:

    Normal textures pair 2,3 should have the same size
    UnityEngine.Debug:LogError(Object)
    ReliefTerrainGlobalSettingsHolder:prepareNormals() (at Assets/ReliefPack/Scripts/ReliefTerrain/_Internal/ReliefTerrainGlobalSettingsHolder.cs:2543)
    ReliefTerrainEditor:OnInspectorGUI() (at Assets/ReliefPack/Editor/ReliefTerrain/ReliefTerrainEditor.cs:602)
    UnityEditor.DockArea:OnGUI()

    Any help with this would be appreciated! :)

    Also, P.S. - I'm still loving the relief terrain pack! The terrains are really nicely textured now and look much better than other games like Far Cry 3 and even Crysis! :D
     
  45. tomaszek

    tomaszek

    Joined:
    Jun 18, 2009
    Posts:
    3,862
    In project view make texture on layer 2 (3rd actually - counted from zero) and texture on layer 3 the same size.

    If on layer 2 normalmap assigned is for example 128x128 and you try to assign 512x512 on layer 3 RTP won't allow it.

    First make 512x512 also 128x128 and then try to assign it.

    There are sometime problematic situations for RTP. Let's say you've got normalmaps assigned on layer 2,3. Then you change the size of one of the textures - RTP doesn't know about it. Refreshing (by button next to the texture splot) will produce error.

    The rule is that normalmaps that are combined in pairs need to be of the same size.

    Tom
     
    Last edited: Jun 14, 2014
  46. chillersanim

    chillersanim

    Joined:
    Mar 31, 2013
    Posts:
    219
    Hello tomaszek

    I've bought your product recently and am now playing around with it.

    Just wanted to say, that it looks great and I'm very happy with the purchase.
    Keep up the great work!

    Greetings
    Chillersanim
     
  47. fredr92

    fredr92

    Joined:
    Jul 8, 2013
    Posts:
    292
    Hi im interested in buying Your package, the results People get, and their reviews speaks for them self .
    But i was just wondering, do you recommand buying world machine too?
    I have made a terrain With the unity Tools and been working on it for a 4 months, but i never get completly satisfied With it.
    So i have been playing around With the free Version off world machine but 513 pixels doesent give good enough results.
    So i want too make a New map and take it up the next Level.
    Cause i cant get erosion effect With unity Tools, and 513 pixels makes the terrain look like lego at Close up.

    what do you recomand? i know Your package is great, and i want it, but do you think it give Nice results on a unity made terrain?

    Hope too hear back from you , thanks.
     
  48. khos85

    khos85

    Joined:
    Jul 21, 2013
    Posts:
    541
    Hi Tom, Nathaniel gave me some assistance, I discovered what I was doing incorrectly :) it was because I had already use wolrdcomposer and imported the terrains... he recommends to first import the RTP plugin, then after that import/use the terrain/worldcomposer, then it all works together! easy as that it seems. Now I just have to got to it and start testing the powerful features of RTP3!

    Cheers,
    Kim
     
  49. bmccall1

    bmccall1

    Joined:
    Jul 28, 2013
    Posts:
    120
    Ok I have, hopefully a simple question. Something somewhere is overwriting my terrains base map dist.

    Before, it was set to 2000, which was fine, because at least it had a long draw distance. However, somehow, its been changed to 23.7 and now my terrain only looks good for 24 meters ahead of me.

    Can you suggest what is overwriting this value? I have no idea what I did but I can't run my game like this.

    Thanks!
     
  50. tomaszek

    tomaszek

    Joined:
    Jun 18, 2009
    Posts:
    3,862
    @chillersanim, good to hear and wish you all the best with your work ! :)

    @fredr92, for my example scene I used World Machine Standard Edition. Pro is quite expensive, but also have more options that I just didn't need. I know that many people uses WM and then render its output with RTP. For example demo island has been made using mudbox and then erosion wass added using WM - http://forum.unity3d.com/threads/the-hermits-code-an-adventure-based-on-the-rtp3-demoscene.197628/

    @khos85, great you get it working at last ! Nathaniel has much more experience using TC / WC and RTP together than me.

    Tom