Trouble preserving LODs with simple scatter Unity HDA

   2189   1   1
User Avatar
Member
8 posts
Joined: Jan. 2017
Online
Hello!

For the past few days I've been trying to make a Unity HDA that instances an object (set by an operator path) to points scattered over another object. I will be using this asset to scatter trees in my scene, so preserving LODs in this process is very important to me.

Currently this is my node setup:


So far, everything works as expected except the LODs are not carried over from the imported .fbx. LODs are present if the .fbx is placed manually, but something in the HDA pipeline is removing them before instancing. “Use LODs” is checked in the HDA in Unity, and I have the copy SOP set to pack and instance.

Also, the HDA works very quickly when placing low poly objects (8 polygons @ 100,000 instances only takes a few seconds) but 10 instances of a larger .fbx (15k polys) makes unity hang for 15 minutes! (but works eventually). For reference, the same objects can be placed in Unity by hand with no hangs or freezing at all.

Thanks for any advice you have, I can't seem to find anyone with this problem elsewhere!
I've attached the project and the HDA if that is useful.

Image Not Found

Image Not Found

Attachments:
scatter.hiplc (175.7 KB)

User Avatar
Member
571 posts
Joined: May 2017
Offline
Note that LODs are not supported if you are using packed primitives (also stated in the docs).

Do you need to import the geometry into Houdini? You can instance without the import stuff if you don't need to. Simply use attribute instancing:
https://www.sidefx.com/docs/unity/_instancing.html#ObjectInstancers_Attribute [www.sidefx.com]

The reason for the large objects being slow is due to a input processing step where shared vertices are merged before uploading to Houdini. I do plan to speed this up in the near future. In the mean time, if you don't need to import into Houdini, then use the attribute instancing method mentioned above.
  • Quick Links