Jump to content

Using terrain details with LoD.


Sam3DX
Go to solution Solved by Peter,

Recommended Posts

Folks, I'm sorry to pull up this topic again but I got responce from the other asset developer and they route me back to the PW.

The change is don on purpose. Unity's internal API does not provide placement data if the prefab contains a LOD Group, so Nature Renderer changes the registered prefab to the first child of the prefab to work around this issue.
It is not possible to disable this behavior of Nature Renderer as Unity also occasionally removes the details or throws an error if the prefab with the LOD Group is registered directly.
 
We recommend contacting the developers of Gaia to ensure that the prefab is recognized by its child as well.

 

Let me sum up the issue:

  1. Unity didn't allowing to use LOD prefab as a terrain detail.
  2. Nevertheless, Gaia still allows us to put a LOD prefab to unity's terrain detail list directly ignoring the unity warnings (it's perfect, ty).
  3. To render this details tho, we need some external rendering system (like Nature Renderer in my case). But according to NR, to make it works this LOD prefab must be replaced with suitable prefab (it's the first child of the LOD group).
  4. Since prefab was changed it brokes the Gaia's spawners, cos it expect to see a LOD prefab on a terrain, but there are different object now (first child of the LOD group). So Gaia spawner just spawn the LOD prefab again, and it will be again changed by NR.

The solution Nature Renderer propose is to ask Gaia to check not only the root LOD prefab but LOD group's first child when we are working with terrain details. Does it make sense? 

Link to comment
Share on other sites

We took a look at this last night, I believe Peter was mentioning something but its still early morning for him. 
 

Link to comment
Share on other sites

Hi @Sam3DX I saw this and I think it makes sense for us to add this to Gaia in one way or another so that anyone using Nature Renderer can profit from this workaround. I should be able to send you a patch for this in the coming days. If you report back it works well we can add this as part of the next Gaia update.

  • Like 1
Link to comment
Share on other sites

  • Solution

@Sam3DX Here is the patch, please install the  unitypackage in the attached .zip file via Assets > Import Package > Custom Package. After it has been installed, Gaia should not create a new terrain detail anymore if it finds another detail on the terrain that uses the same mesh as the first LOD on the object in the Gaia resource settings.
This should prevent Gaia adding the same detail over and over after Nature Renderer changed the prototype on the terrain.


GaiaNatureRendererPatch.zip

  • Like 1
Link to comment
Share on other sites

4 hours ago, Peter said:

@Sam3DX Here is the patch, please install the  unitypackage in the attached .zip file via Assets > Import Package > Custom Package. After it has been installed, Gaia should not create a new terrain detail anymore if it finds another detail on the terrain that uses the same mesh as the first LOD on the object in the Gaia resource settings.
This should prevent Gaia adding the same detail over and over after Nature Renderer changed the prototype on the terrain.


GaiaNatureRendererPatch.zip 14.66 kB · 0 downloads

AWESOME! Thanks a lot! I'll check it out and report. 

Link to comment
Share on other sites

@Peter I'm happy to report that Nature Renderer now working with Gaia LODded deatails spawners! Thanks a lot for your cooperation! ❤️ 

PS. It doesn't work with GayaScenePlayer/Terrain Culling tho, but that's a completely different case that probably deserve a separate report. 

  • Like 1
Link to comment
Share on other sites

On 7/30/2022 at 4:19 AM, Sam3DX said:

PS. It doesn't work with GayaScenePlayer/Terrain Culling tho, but that's a completely different case that probably deserve a separate report. 

I could imagine that there needs to be an initialization process of sorts when a new terrain is being loaded into the scene. Maybe the documentation of Nature Renderer provides some info about additive scene / terrain loading. If you make a separate report, please start a new thread so future users can find it under the correct title.

  • Like 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Tell a friend

    Love Canopy - Procedural Worlds? Tell a friend!
  • Need help?

    We work with some of the biggest brands in global gaming, automotive, technology, and government to create environments, games, simulations, and product launches for desktop, mobile, and VR.

    Our unique expertise and technology enable us to deliver solutions that look and run better at a fraction of the time and cost of a typical project.

    Check out some of our non-NDA work in the Gallery, and then Contact Us to accelerate your next project!

×
×
  • Create New...