Search Unity

Terrain Composer2 a next generation GPU powered terrain tool.

Discussion in 'Assets and Asset Store' started by eagle555, Sep 16, 2012.

  1. GXMark

    GXMark

    Joined:
    Oct 13, 2012
    Posts:
    514
    Terrain loading does not correctly work for different saved file prefabs.

    For example

    TerrainPreview saved to TerrainPreview.prefab
    TerrainRegion saved to TerrainRegion.prefab

    Loading these prefabs does not load the correct terrains.
     
  2. eagle555

    eagle555

    Joined:
    Aug 28, 2011
    Posts:
    2,705
    The terrains on default are not loaded into a TC project, because you might already have terrains in the TC terrain list and in the Hierarchy you want to use. I build this in later, because it was annoying that everytime I wanted to load an example or preset the terrains got changed in the list.

    You can however enable the loading, to do this go to TC Menu -> Options -> Generate Settings -> Load Terrain Data (Enable). This still only load them into the TC terrain list and doesn't put the terrains into the hierarchy, you have to do that manually. Because terrain in Unity are saved as TerrainData's in your project. So if you use the same TerrainData's on more Scene's, altering them in one Scene will results in altered ones in the other Scenes as well. This quickly can become confusing and unwanted, that's why I use the current work-flow.

    Nathaniel
     
  3. puzzlekings

    puzzlekings

    Joined:
    Sep 6, 2012
    Posts:
    404
    Thanks Nathaniel

    Ok, I have been able to generate a normal map :)

    Actually I don't think I need a colormap - what I need is the combined overall diffuse texture for the terrain so I can put this into sky shop (along with the normal map)

    Is there a way to generate this from TC?

    cheers

    Nalin
     
  4. DreamEnder

    DreamEnder

    Joined:
    Apr 12, 2011
    Posts:
    191
    Is it possible to place the trees into a parent game object instead of the terrain? Exactly how the stones are placed.
     
  5. OneThree

    OneThree

    Joined:
    Oct 28, 2011
    Posts:
    181
    Very sorry to ask a question I'm sure has been answered here already, but 30 pages is a lot to search post by post. :)

    Anyway, I have a quick question: does TerrainComposer support holes in the terrain? As in, making tunnels under the terrain or making caves. I know that the architecture of the tunnels themselves would need to be meshes from another tool, but cutting the hole into those tunnels is a terrain question ...
     
  6. eagle555

    eagle555

    Joined:
    Aug 28, 2011
    Posts:
    2,705
    Hello Nalin,

    For best terrain visual quality it's best to make a colormap, instead of using the average color for each splat texture. As this is exactly what Unity terrain already does automatically and it's called 'base map' and the resolution for this texture is called 'basemap resolution'. So you can either leave the skyshop colormap slot empty or make a colormap. The idea behind a colormap is that normally you are bound to the colors of your splat textures, but with a colormap these can be multiplied and then you can have much more variation in colors on your terrain, which makes it look less repetitive and more colorful.

    Nathaniel
     
  7. eagle555

    eagle555

    Joined:
    Aug 28, 2011
    Posts:
    2,705
    Yes you can place trees as objects with TC, but....Trees are part of the Unity terrain system, they are stored in an array in terrain.terrainData.treeInstances as a TreePrototype class, and this system includes tree distance culling, billboard system (billboard fading to 3d tree), etc. This makes it run a lot faster then if you would use trees as objects (3d trees everywhere).

    Nathaniel
     
  8. eagle555

    eagle555

    Joined:
    Aug 28, 2011
    Posts:
    2,705
    TerrainComposer uses standard Unity terrain, and this is not directly supported by the standard Unity terrain shader. But you can do it with RTP3.1 :


    And yes for the caves/tunnels you would need meshes.

    Nathaniel
     
  9. puzzlekings

    puzzlekings

    Joined:
    Sep 6, 2012
    Posts:
    404
    Thanks Nathaniel


    Skyshop has a diffuse slot for viewing a terrain over a further distance so I am after a diffuse map to put into there ( I already have a normal map). The skyshop specular shader interpolates between the individual tile map textures at close distance and the base diffuse/normal map at further distances.

    it's called 'base map'

    I cannot see where this might be generated, so I wondered if TC could simply write out the overall diffuse map?

    Hope this makes sense :)

    N
     
  10. AlteredPlanets

    AlteredPlanets

    Joined:
    Aug 12, 2013
    Posts:
    455


    this video does not show how you set up rtp for TC intially, how do you save that prefab for rtp?

    starting at 1:33
     
  11. OneThree

    OneThree

    Joined:
    Oct 28, 2011
    Posts:
    181
    Awesome, thanks for the quick reply. One last question: is RTP compatible with Terrain Composer? Just curious if I could use Terrain Composer to create the basic terrain, then hop in with RTP to cut holes.
     
  12. primus88

    primus88

    Joined:
    May 14, 2013
    Posts:
    611
    I have some serious issuer with the unity navmesh baking (it does not follow correctly the terrain mesh).

    Now I'm thinking to model the terrain and then cut it and stitch back after that using the terrain composer.
    Is it possible for the terrain composer to work with ready made terrains and still be able to apply the rest of the features that the terrain composer offers?

    Thanks
     
  13. eagle555

    eagle555

    Joined:
    Aug 28, 2011
    Posts:
    2,705
    Skyshop should have something to make this, RTP has this. As on Unity default terrain shader this is not needed as it does it automatically, so I didn't include this in TerrainComposer as there was no need for it.

    Nathaniel
     
  14. eagle555

    eagle555

    Joined:
    Aug 28, 2011
    Posts:
    2,705
    There's load and save button if you click the RTP tab in TC.
    Tom upgraded the saving in RTP3.1, you can do that in RTP directly. How to do this is descriped in RTP documentation:
    https://www.assetstore.unity3d.com/#!/content/5664 (documentation pdf).

    Nathaniel
     
  15. eagle555

    eagle555

    Joined:
    Aug 28, 2011
    Posts:
    2,705
    Yes you can do that. Tom (the developer of RTP) and I are collaborating together, our packages are very compatible.

    Nathaniel
     
  16. eagle555

    eagle555

    Joined:
    Aug 28, 2011
    Posts:
    2,705
    With ready made heightmap Unity terrains. Yes this is possible, all you need to do is drag and drop your ready made terrain(s) in the TC terrain list slot(s). Can click '+' button to add more slots.

    Nathaniel
     
  17. AlteredPlanets

    AlteredPlanets

    Joined:
    Aug 12, 2013
    Posts:
    455
    Yea but RTP saves out a .asset file and in TC to load, its need to be a .prefab file.
     
  18. puzzlekings

    puzzlekings

    Joined:
    Sep 6, 2012
    Posts:
    404
    Unfortunately Skyshop has no such facility as it is purely an IBL solution :( as on the demos it shows simply importing these from world machine.

    I would have thought the logical place to put this within TC would have been exactly where one exports a normal map, but instead having this as a defuse.prefab under save/layers/output maps ?

    Please Nathaniel could there be any chance of this in the future at all?

    thanks,

    Nalin
     
  19. DreamEnder

    DreamEnder

    Joined:
    Apr 12, 2011
    Posts:
    191
    Hey Nathaniel,

    Thanks for the response. I'm trying to add trees using the object placement but they keep getting added to terrain that is under water. Is there any way to prevent this?

    Also is there a way to make all the terrain edges tamper off? Like an island.
     
  20. AlteredPlanets

    AlteredPlanets

    Joined:
    Aug 12, 2013
    Posts:
    455
    Hey Nathaniel ,

    Please check your skype, I messaged you a solution to how you can help my issue.
     
  21. Eric1005

    Eric1005

    Joined:
    Sep 22, 2014
    Posts:
    3
    Hey Nathaniel,

    I have some issues with build a scene for Windows Phone 8.

    Unity reports this error:

    Error building Player: Exception: Error: method `System.Byte[] System.IO.File::ReadAllBytes(System.String)` doesn't exist in target framework. It is referenced from Assembly-UnityScript at System.Void terraincomposer_save::load_raw_heightmaps().
    Error: method `System.Byte[] System.IO.File::ReadAllBytes(System.String)` doesn't exist in target framework. It is referenced from Assembly-UnityScript at System.Void terraincomposer_save::load_raw_subfilter(filter_class,System.Int32,System.Int32).

    Eric
     
  22. AlteredPlanets

    AlteredPlanets

    Joined:
    Aug 12, 2013
    Posts:
    455
    Can someone share the rtp with terrain composer workflow, if you add me on skype and help me through it and all goes successfully... I will paypal you $50

    Sherrod Fletcher : Skype
     
    Last edited: Sep 22, 2014
  23. eagle555

    eagle555

    Joined:
    Aug 28, 2011
    Posts:
    2,705
    Yes you can either load/save presets with RTP (.asset) or you can load/save with TC (.prefab).
     
  24. j1e3s5

    j1e3s5

    Joined:
    Aug 23, 2014
    Posts:
    18
    hello, i recently bought the terrain composer and have been tweeking and trying things with it for the past few days.
    however every time i try to have more than a 2x2 in terrain tiles when i try to run the game it crashes. so basically more than 4 total terrain tiles at 1000 length and width each and it will crash. i read somewhere it had to do with the total amount of trees but i put the settings down and make it so they should turn to billboards and whatnot. im confused how to get larger terrains running.

    i tried purchasing the dynamic map system from the unity asset store but cant get it working, its supposed to load terrain pieces when you get near them i thought that would reduce the amount of trees and loading time. but i cant get it too work. any ideas?

    is it because i have too many trees? i did have several thousand total like anywhere from 10,000-60,000 but i thought they would be turned to billboards and whatnot so only like a few would actually be models. im very new to unity so im pretty confused. any help would be much appreciated thank you.
     
  25. toxtronyx

    toxtronyx

    Joined:
    Aug 21, 2014
    Posts:
    114
    Hi Nathaniel,

    I have a question (probably asked before, but I am too dumb to find it). I want to place prefabs via terrain composer. For example the same house a couple of times. So I dragged the created prefabs into terrain composer, set up all the masks and filters and my houses get created were I want them to be. Unfortunately Unity does not seem to accept them as prefabs anymore. Is there a way to place prefabs instead of meshes with terrain composer?

    TIA
     
  26. toxtronyx

    toxtronyx

    Joined:
    Aug 21, 2014
    Posts:
    114
    Nevermind. Found it accidentally ;-)
     
  27. pushingpandas

    pushingpandas

    Joined:
    Jan 12, 2013
    Posts:
    1,419
  28. eagle555

    eagle555

    Joined:
    Aug 28, 2011
    Posts:
    2,705
    We solved it on skype :)

    Nathaniel
     
  29. eagle555

    eagle555

    Joined:
    Aug 28, 2011
    Posts:
    2,705
    Yes you can do that by using masks and then with input on 'height'. I show this technique in many tutorial video's and it works the same for every output:
    http://www.terraincomposer.com/tutorials/
    - Help Video Placing Trees
    - Help Video Heightmap and splat texturing mask

    Nathaniel
     
  30. eagle555

    eagle555

    Joined:
    Aug 28, 2011
    Posts:
    2,705
    Hello Eric,

    This happens because in Windows phone 8 it isn't allowed to access the harddrive with .net IO in a monobehaviour script. I made a fix for this, let me know if it works...


    Nathaniel
     

    Attached Files:

  31. eagle555

    eagle555

    Joined:
    Aug 28, 2011
    Posts:
    2,705
    Hello,

    Your amount of trees is ok, so that can't be the issue. It is proberly to high resolutions you choose. Can you show a screenshot of the resolutions in TC Terrain List -> Resolutions?

    Nathaniel
     
  32. eagle555

    eagle555

    Joined:
    Aug 28, 2011
    Posts:
    2,705
    Hello,

    Yes you can enable this for each object if you unfold the object and then in settings enable 'Prefab Link'.

    Nathaniel
     
  33. toxtronyx

    toxtronyx

    Joined:
    Aug 21, 2014
    Posts:
    114
    Yep and it works great. By the way. I use worldcomposer to get the satellite data, process the stuff via terraincomposer and use the results together with RTP. This saved me months of work. I love it! Ok enough of the kind words I have hundreds of square miles to complete ;-)
     
  34. j1e3s5

    j1e3s5

    Joined:
    Aug 23, 2014
    Posts:
    18
    i literally am using the lowest resolutions possible and it still crashes, heightmap is 33, splatmap and basemap are both 16, and grass resolution is at 64 for each terrain, i have 25 terrains at 1000 width and length each. it still crashes. pretty fusterating...hope its not related to some script or something. im going to try it in a new project and see what happens. any other ideas? my trees are at 65,000 total. you sure thats not to much? im very confused.
     
  35. eagle555

    eagle555

    Joined:
    Aug 28, 2011
    Posts:
    2,705
    That is strange and shouldn't happen. Although and can have to do with your tree distance settings. If that is too far Unity terrain will render it all 3d trees and that might cause a crash. You can check it in TC Terrain List -> Settings (for Editor and Runtime).

    If that doesn't help I suggest we do a skype screenshare. My account is Nathaniel.Doldersum

    Nathaniel
     
  36. j1e3s5

    j1e3s5

    Joined:
    Aug 23, 2014
    Posts:
    18
    basemap distance and tree distance are both at 1000. is this too high? very confused. ill add you on skype and hopefully sometime we can try to fix this. thank you. my name should be jessecook135.
     
  37. puzzlekings

    puzzlekings

    Joined:
    Sep 6, 2012
    Posts:
    404
  38. Gregory-

    Gregory-

    Joined:
    Sep 25, 2014
    Posts:
    3
    Hi Nathaniel,
    Is there any way to automate the apply of the splat texture (real orthophoto) to the tree mask by selecting the name of the texture or the name of the terrain instead of the tiles%x%y rules ?
    I have +300 terrains forming a non rectangular global tiles so

    Thanks for your help, (and for this great tool !!!)
     
  39. eagle555

    eagle555

    Joined:
    Aug 28, 2011
    Posts:
    2,705
    Yes we talked on skype, I think it has to do with your tree prefab...

    Nathaniel
     
  40. eagle555

    eagle555

    Joined:
    Aug 28, 2011
    Posts:
    2,705
    Ah yes it seems to work :).

    Nathaniel
     
  41. eagle555

    eagle555

    Joined:
    Aug 28, 2011
    Posts:
    2,705
    No this is not possible without having %x%y rules...

    Nathaniel
     
  42. knotFF

    knotFF

    Joined:
    Apr 13, 2013
    Posts:
    66
    Hello.

    I am getting a strange behaviour with my scene when placing vegetation. For some reason, when I place certain prefabs using TC the objects get culled when near and show only as billboards and strangely lit (black in most cases).
    The same vegetation placed by hand or using the default terrain tools, displays correctly.

    In the image bellow you can see the vegetation placed by TC in the background (billboard only) and the vegetation near the camera, which was placed by the default terrain tools.
    http://www.rgbirdgames.com/ftp/permalink/140929_/Near.png

    In this second image, you can see that indeed there was vegetation around the area of the previous shot.
    http://www.rgbirdgames.com/ftp/permalink/140929_/Far.png

    Any clues?
    Thanks.
    F.
     
  43. Eric1005

    Eric1005

    Joined:
    Sep 22, 2014
    Posts:
    3
    Hi Nathaniel,

    I have tried this package but now get a few errors like this:

    Assets/TerrainComposer/Scripts/terraincomposer_save.js(2987,102): BCE0019: 'parentObjectsTerrain' is not a member of 'settings_class'.

    or this

    Assets/TerrainComposer/Scripts/terraincomposer_save.js(2988,189): BCE0019: 'objectParent' is not a member of 'terrain_class'.

    Thanks

    Eric
     
  44. Deleted User

    Deleted User

    Guest

    Hey, purchased yesterday..I have world composer and have been publishing strictly to android mobile.I was debating very hard , if I should just get Terrain 4 Mobile, for a short-term quick solution...Now I am taking my WC Terrains, using the Free Terrain to Obj exporter, then in in maya UV, rotate, export to fbx to unity, 16 large tiles, 4 hours..but no splat maps..I want more detail close up, fading to satellite, from the distance, as well as LOD meshes and textures, at any given time, only one block is at full LOD. Using Sector Complete, Stream and Viz..and Unity Pro..I am getting good frame rates..

    but.I have questions..

    In WC Height map Resolution..what is the check box and the number in parenthesis (I feel stupid).

    ..Can I just delete the whole TC folder, when I am done, building to apk?

    any advice, lessons learned from your mobile flight sim experience? How to best use the Convert terrain to Meshes functionality?? or dealing with low end mobile devices in this genre?

    Thanks.

    Patrick

    p.s.
    , my result..before and after

    From WC:Terrain


    and after TC Convert Terrains to mesh:



    so obviously not built for this...have you got it to work?

    What am I doing wrong?



    -- Update: It is how you are generating UVs...the terrain mesh UV's are scaled and shifted..see:



    ---I was able to export All meshes to objs,(with another free script) and now I can fix all the uv's, create my LODs,, then back to FBX..
     
    Last edited by a moderator: Oct 1, 2014
  45. AndyNeoman

    AndyNeoman

    Joined:
    Sep 28, 2014
    Posts:
    938
    Amazing Assets well done OP.

    I will be purchasing the Terrain and RTP shaders when my game gets out of prototype stage.
     
  46. Undiscovered

    Undiscovered

    Joined:
    Apr 5, 2014
    Posts:
    53

    Hi again,

    I have now stumbled across another issue which I have spent a while trying to correct, but unfortunately I have not came up with a solution.

    As seen in the attached images there is a section of the terrain which does not contain any the detailed texture. You can also see that there is a peculiar black shadowing line on the terrain. If someone can help clear these issues up it would be much appreciated.



    Many Thanks!
     
  47. Undiscovered

    Undiscovered

    Joined:
    Apr 5, 2014
    Posts:
    53
    Not to worry, It turns out that I had the Textures wrap mode set to "Clamp"
     
  48. Aestyr

    Aestyr

    Joined:
    Oct 4, 2014
    Posts:
    3
    For some reason I seem unable to get the heightmap to show; http://prntscr.com/4sxm4t . I tweak all of the settings but still can't get a change.
     
  49. Undiscovered

    Undiscovered

    Joined:
    Apr 5, 2014
    Posts:
    53
    Hi Aestyr,
    From what I can see & understand you need to change the 'Input' tab to either Raw Heightmap(if you are using a RAW file) or to Image.
     
  50. Aestyr

    Aestyr

    Joined:
    Oct 4, 2014
    Posts:
    3
    Hey Undiscovered,
    I've done this and it still doesn't seem to work, the screenshot I had was from drying to get the default perlin curve to work however that doesn't show either unless I change the position.