Search Unity

► Terrain to Mesh ◄

Discussion in 'Assets and Asset Store' started by Arkhivrag, Oct 1, 2015.

  1. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,978

    Attached Files:

    Last edited: Jun 12, 2021
    silvematt, Amplify_Ricardo and Gozdek like this.
  2. Games-Foundry

    Games-Foundry

    Joined:
    May 19, 2011
    Posts:
    632
    Interesting. What about handling LOD cases where you want the number of boundary vertices to match your LOD0 so that you don't get gaps in terrain further away?
     
  3. 99thmonkey

    99thmonkey

    Joined:
    Aug 10, 2012
    Posts:
    525
    Looks cool. Would be fun if you could easily MM all the plants, trees and grasses as well.
     
  4. buttmatrix

    buttmatrix

    Joined:
    Mar 23, 2015
    Posts:
    609
    What about this?
     
  5. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,978
    You can generate multiple version of mesh with different amount of vertices and chunks.
    But what you are asking - Having fixed vertex amount on chunk perimeter and reduce vertex count inside? No, currently Terrain To Mesh can not do that.


    Terrain plants, trees and grass are just planes with cutout shaders, if you try to MM :) (use Mesh Materializer) on them, they just will be converted to planes (most of them to cross planes). Do not see use of it.
    But thanks for question, I've just realized that I can add SpeedTree converter to Mesh Materializer (next update).


    Which of below features is there?
    1. Ultra fast converter algorithm.
    2. Vertex count control - you will always know how much vertices will have final mesh.
    3. Terrain can be split in any amount of pieces(chunks) - perfect for occlusion culling (especially for mobiles).
    4. Optional uv, uv2, normal and tangents calculator.
    5. All above works in editor and run-time.
    6. Can export terrain splatmaps.
    7. OBJ file exporter
    Only last one - OBJ file exporter.



    Amazing Assets - YouTube Facebook Twitter
     
    Last edited: Mar 2, 2020
    buttmatrix and theANMATOR2b like this.
  6. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,978
  7. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    13,349
    Very nice, can it convert multiple tarrains to one mesh too ?

    Thanks
     
  8. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,978
    I have not thought about that. Added to a 'wish list'.



    Amazing Assets - YouTube Facebook Twitter
     
    Last edited: Mar 2, 2020
    nasos_333 likes this.
  9. nasos_333

    nasos_333

    Joined:
    Feb 13, 2013
    Posts:
    13,349
    Would be rather useful.

    I just realized this pack is included in one i own too :)
     
  10. Games-Foundry

    Games-Foundry

    Joined:
    May 19, 2011
    Posts:
    632
  11. gterveen

    gterveen

    Joined:
    Dec 17, 2012
    Posts:
    22
    Will I keep the textures on the terrain?
     
  12. buttmatrix

    buttmatrix

    Joined:
    Mar 23, 2015
    Posts:
    609
    Is Terrain to Mesh compatible with Relief Terrain Pack shaders?
     
  13. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,978
    Yes, I guess. That feature is not implemented.


    Terrain To Mesh can generate uv coordinates for new mesh so textures can be used.
    Also package includes one 'bonus' shader that blends 4 textures using splat map. It can recreate original textured terrain. You can modify shader to support more or less blend textures.


    Terrain To Mesh needs TerrainData not some custom shaders used by it. If Relief Terrain Pack uses Unity terrain then yes, it is compatible.



    Amazing Assets - YouTube Facebook Twitter
     
    Last edited: Mar 2, 2020
  14. spacetrotter

    spacetrotter

    Joined:
    Jun 22, 2015
    Posts:
    5
    there is a bug,on unity 5.13 upload_2015-11-2_2-3-0.png
     
  15. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,978
    Tested on Unity 5.1.2 and 5.2, no bugs found.
    Can you provide more details, or that image tells nothing. Maybe it's Unity's editor exception and not assets bug?



    Amazing Assets - YouTube Facebook Twitter
     
    Last edited: Mar 2, 2020
  16. spacetrotter

    spacetrotter

    Joined:
    Jun 22, 2015
    Posts:
    5
    when i open the terrain to mesh window,it shows nothing
    upload_2015-11-2_2-30-23.png
     
  17. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,978
    Did you move VacuumShaders folder? It must be inside main Assets folder, not in any other subfolders.
    Do you have other plugins inside project?



    Amazing Assets - YouTube Facebook Twitter
     
    Last edited: Mar 2, 2020
  18. spacetrotter

    spacetrotter

    Joined:
    Jun 22, 2015
    Posts:
    5
    i create a new project ,console show no error but i can't drag the terrain to window
    upload_2015-11-2_2-36-37.png
     
  19. spacetrotter

    spacetrotter

    Joined:
    Jun 22, 2015
    Posts:
    5
    upload_2015-11-2_2-37-56.png
    I can't choose a terrain,after i click snow terrain nothing happon
     
  20. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,978
    Try select terrain inside Hierarchy window and then use context menu inside window.

    terrain-to-mesh-pickup.png



    Amazing Assets - YouTube Facebook Twitter
     
    Last edited: Mar 2, 2020
  21. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,978
    Above screenshot shows that you are trying to load terrain from assets.
    Terrain that you want converted must be gameobject not asset and it must be inside scene.



    Amazing Assets - YouTube Facebook Twitter
     
    Last edited: Mar 2, 2020
  22. spacetrotter

    spacetrotter

    Joined:
    Jun 22, 2015
    Posts:
    5
    ok i know thank you
     
  23. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,978
    I'll try to reconstruct issue that terrain can not be dragged and fix it (if it is asset's bug of course).

    Edit
    Yes, it Unity's bug, but I've found how to overcome it. Will release update tomorrow.



    Amazing Assets - YouTube Facebook Twitter
     
    Last edited: Mar 2, 2020
  24. zugsoft

    zugsoft

    Joined:
    Apr 23, 2014
    Posts:
    453
    I just bought yuor Asset, and I have the same issue.
    I can't use the Terrain at all.

     
  25. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,978
    Yes, it is already fixed. Update will be available tomorrow.
    For now, select terrain inside hierarchy window and then use context menu pick up.





    Amazing Assets - YouTube Facebook Twitter
     
    Last edited: Mar 2, 2020
  26. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,978
    Update v1.01 released.
    • Fixed drag and drop problem for editor window.



    Amazing Assets - YouTube Facebook Twitter
     
    Last edited: Mar 2, 2020
    theANMATOR2b likes this.
  27. zugsoft

    zugsoft

    Joined:
    Apr 23, 2014
    Posts:
    453
    I can export my terrain to mesh with splat map for Mobile.
    With a Mobile Shader it will be perfect.
     
  28. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,978
    Is it a question or just a statement?



    Amazing Assets - YouTube Facebook Twitter
     
    Last edited: Mar 2, 2020
  29. angel_m

    angel_m

    Joined:
    Nov 4, 2005
    Posts:
    1,160
    Please, could I see the docs before purchasing?
    Thanks
     
  30. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,978
    Last edited: Mar 2, 2020
  31. angel_m

    angel_m

    Joined:
    Nov 4, 2005
    Posts:
    1,160
    Is the shader included as a bonus suitable for using on mobile (SM 2.0)?
     
  32. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,978
    Included shader is for example scene and it blends 4 textures using control texture.
    It uses Unity surface shader.

    But as I have received several messages about that exactly shader to make it mobile, I plan to add shaders with 2 to 8 textures blend support, including bump map. There will be Unlit, One Directional Light and PBR shaders.
    Will try to make next update for the next week.



    Amazing Assets - YouTube Facebook Twitter
     
    Last edited: Mar 2, 2020
    theANMATOR2b likes this.
  33. zugsoft

    zugsoft

    Joined:
    Apr 23, 2014
    Posts:
    453
    Your asset wor
    It's just a statement, your Asset works very fine, and very easy to use.
    I bought TerrainComposer to transform my Terrain to mesh, and use splatmap, but I didn't find the process to achieve this.

    Your Asset is better and eaysier.

    With a Mobile shader it will be perfect.
     
  34. pretender

    pretender

    Joined:
    Mar 6, 2010
    Posts:
    865
    Please do mobile shader and I will buy this asset at once
     
  35. zugsoft

    zugsoft

    Joined:
    Apr 23, 2014
    Posts:
    453
    With your shader, my mobile game fps drop by 33%
    With the mobile bump mapping shader I have between 58-60 fps, and only 30-40 fps with your's
    I am a C# developer, I never understood Shader lol
     
  36. angel_m

    angel_m

    Joined:
    Nov 4, 2005
    Posts:
    1,160
    I think now TM4 is DEPRECATED, and no more mesh terrain for mobile is available on the asset store I think Arkhivrag has the opportunity to make a good product to create and texture mesh terrains for mobile with many potential buyers.
     
  37. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,978
    Package is for fastest converting Terrain to Mesh.
    Shader you guys are talking about is just for example scene and purpose of this asset has never been any 'mobile' or any other type of shaders.

    But as I have received much (too much) shader requests I will update package (as wrote above) with full range of shaders with 2 to 8 textures sampling and bump effect. Shaders will be for mobile (Unlit and One Directional Light) and PBR type.


    Edit:
    Shaders will be Curved World compatible!



    Amazing Assets - YouTube Facebook Twitter
     
    Last edited: Mar 2, 2020
    twobob and 99thmonkey like this.
  38. zugsoft

    zugsoft

    Joined:
    Apr 23, 2014
    Posts:
    453
    I created 3 Mobile shaders for Terrain to mesh.
    With 2 textures my fps is 59-60
    With 3 textures my fps is 56-58
    With 4 textures my fps is 54-55

    I am very happy with the result.
    I will make a apk
     
  39. pretender

    pretender

    Joined:
    Mar 6, 2010
    Posts:
    865
    is there are a chance you can share it
     
  40. angel_m

    angel_m

    Joined:
    Nov 4, 2005
    Posts:
    1,160
    +1
     
  41. angel_m

    angel_m

    Joined:
    Nov 4, 2005
    Posts:
    1,160
    The price was raised to 25 $ in only 6 days...
     
  42. Analist-Group

    Analist-Group

    Joined:
    Dec 28, 2014
    Posts:
    1
    The public API can export terrain to obj format with splatmap texture in game time?
     
  43. DarkArts-Studios

    DarkArts-Studios

    Joined:
    May 2, 2013
    Posts:
    389
    I apparently own this as part of Mesh Materializer.

    How do I get UVs and tangents for terrains within Mesh Materializer?

    My projectors, onto terrains, gave issues. So I thought I'd try this and I'm getting the same problems, presumably due to normals/tangents.

    Thank you
     
  44. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,978
    Price changed exactly after one week, as was written. Today is 8th day.

    No.

    Missing(New) features will be added to Mesh Materializer in next update (about in 2 weeks).
    Do you have normal/tangents problem with Terrain To Mesh asset?




    Amazing Assets - YouTube Facebook Twitter
     
    Last edited: Mar 2, 2020
    theANMATOR2b likes this.
  45. zugsoft

    zugsoft

    Joined:
    Apr 23, 2014
    Posts:
    453
  46. virtuali

    virtuali

    Joined:
    May 5, 2014
    Posts:
    1
    Hello, I've just bought this utility, and I have the following problem: if I have several adjacent terrains, exporting to .OBJ into 3DS Max seems to use coordinates relative to their own center, so all chunks end up in the same place, as if their Transformation is being ignored.

    Also, they appear to be rotated 180 degrees when seen in Max.
     
  47. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,978
    Converted terrain (Unity mesh assets and obj files) data is always calculated by local coordinates and pivot point is at (0, 0, 0). It is defined by Unity terrain itself and not by conversion script.
    Also, Unity transforms translate/rotation/scale are not applied.

    OBJ file is generated by this format https://en.wikipedia.org/wiki/Wavefront_.obj_file
    In different coordinate system mesh will be rotated/flipped and you will have to manually adjust it.



    Amazing Assets - YouTube Facebook Twitter
     
    Last edited: Mar 2, 2020
  48. Arkhivrag

    Arkhivrag

    Joined:
    Apr 25, 2012
    Posts:
    2,978
    Update v1.02
    • VacuumShaders assets synchronization. Required update for all VacuumShaders assets.
    • Added full range of shaders with 2 to 8 texture blending, including bumped effect. Shaders support mobile (Unlit and One Directional Light), Legacy and Unity 5 Standard shading models. Shaders are Curved World compatible.



    Amazing Assets - YouTube Facebook Twitter
     
    Last edited: Mar 2, 2020
    99thmonkey likes this.
  49. pretender

    pretender

    Joined:
    Mar 6, 2010
    Posts:
    865
    Hi! I am having trouble understanding how to use splatmaps...can you explain further, I don't have much experience with this. Here is what I did:

    1.) Select terrain I want converted
    2.) Open Terrain to Mesh (Choose export splatmaps,choose export Unity Mesh)
    3.) Click Generate

    I get prefab with mesh with standard shader and I get
    New Terrain 4_SplatAlpha 0
    New Terrain 4_SplatAlpha 1
    New Terrain 4_SplatAlpha 2
    New Terrain 4_SplatAlpha 3
    New Terrain 4_SplatAlpha 4

    Change standard shader to Vacuum Shaders/Terrain To Mesh/Diffuse (It has five slots)
    The question is in what slot goes what? Do I need to locate textures I used for painting on the terrain and put them there
    or I need to do something else?

    I plan this to be used on mobile, what settings you would suggest?
    Do i need both UnityMesh and Obj Mesh?

    I know this should be simple enough to get on the first try :) Help!
     
  50. pretender

    pretender

    Joined:
    Mar 6, 2010
    Posts:
    865
    what settings you used for snow scene? I can't get one splat map