Proper way of splitting instancers?

   2465   4   1
User Avatar
Member
6 posts
Joined: 7月 2021
Offline
Hi, everyone!

I am trying to create several Static Mesh Instance Components in UE4 using plug-in.

Documentation says: "using the unreal_material attribute as the unreal_split_attr attribute (unreal_split_attr =" unreal_material ") will create an instancer component for each material on the second attribute".

I cant reach this kind of behavior. I am recieving single component. I also tried to use pack SOP as it works fine to seprate static meshes to different outputs. This approach seems not working niether with point clouds marked unreal_instance attribute, nor mesh_sockets.

So, is there a way of splitting instancers?
User Avatar
Member
17 posts
Joined: 5月 2021
Offline
Hi stpiton,

There are two things to setup to get instancers to split:

First, make sure to set the unreal_split_attr to the name of the attribute you want to split on.

"As an example, using the unreal_material attribute as the unreal_split_attr attribute (unreal_split_attr = "unreal_material") will create an instancer component for each material on the second attribute. If three different materials are used, the instancer will be split to three different instancer components."https://www.sidefx.com/docs/unreal/_instancing.html [www.sidefx.com]

Second, make sure to the correct attributes are set on the points (see attached image)


This will make the plugin create 2 instanced static mesh components, one for each material.

Hope that helps

Attachments:
splitinstancers.PNG (510.9 KB)

User Avatar
Member
6 posts
Joined: 7月 2021
Offline
Hi, bobc! Thanks for quick respond.

I'm new to Houdini and can missunderstand something. You create @unreal_split_attr BEFORE @unreal_material. How do you link values? Hscript? Or you just leave it empty?

The way I implement it is adding Wrangle after assigning unreal_material to create s@unreal_split_attr and link it's value to @unreal_material. May be this approuch cause the issue? Because I still getting one single instancer in ue.
Edited by stpiton - 2021年8月21日 11:01:30

Attachments:
Splittinginstancers.hda (28.0 KB)
hda_setup.PNG (334.4 KB)
unreal_output.PNG (770.2 KB)

User Avatar
Member
17 posts
Joined: 5月 2021
Offline
Hi stpiton,

The unreal_split_attr is just a string that specifies the name of the attribute to use for splitting:

Attachments:
unreal_split_attr.PNG (105.1 KB)

User Avatar
Member
6 posts
Joined: 7月 2021
Offline
Now I see! unreal_split_attr's value must contain another attribute name, while I was trying to link it to another atribute value.

Thanx a lot, bobc! You made my day!
  • Quick Links