Hello
I am new to Unreal Engine, but I have been using Houdini for years. I created parts for a pedestrian walkway in Houdini, instanced them, and brought them into Unreal Engine 5.1 with two HDAs. Everything is working as expected, but I am having trouble instancing the materials. I created three versions of the material used for the main support beams and used the "Attribute Randomize" node with the custom discrete set on the packed points in the HDA. The geo spreadsheet appears to show variations on the string value of the primitives, but when I bring it into Unreal Engine, each instance is the same material.
Ive added some pics .
THNX for reading
Instancing Materials in Unreal Engine 5.1
2324 3 0-
- Justin Courneya
- Member
- 18 posts
- Joined: Nov. 2015
- Offline
-
- dpernuit
- Staff
- 541 posts
- Joined: Sept. 2016
- Offline
Hi,
Likely the plugin is only creating one instancer for the beams as they are using the same mesh.
An instancer can only use one material, so it's using only the first one and ignoring the other.
You should tell the plugin to create multiple instancers, one for each unique value of the "unreal_material_instance" attribute.
You can do this by adding the unreal_split_attr attribute:
s@unreal_split_attr = "unreal_material_instance";
Likely the plugin is only creating one instancer for the beams as they are using the same mesh.
An instancer can only use one material, so it's using only the first one and ignoring the other.
You should tell the plugin to create multiple instancers, one for each unique value of the "unreal_material_instance" attribute.
You can do this by adding the unreal_split_attr attribute:
s@unreal_split_attr = "unreal_material_instance";
-
- leKryuk
- Member
- 5 posts
- Joined: Sept. 2022
- Offline
dpernuit
Hi,
Likely the plugin is only creating one instancer for the beams as they are using the same mesh.
An instancer can only use one material, so it's using only the first one and ignoring the other.
You should tell the plugin to create multiple instancers, one for each unique value of the "unreal_material_instance" attribute.
You can do this by adding the unreal_split_attr attribute:
s@unreal_split_attr = "unreal_material_instance";
Hello Damien,
Thank you for providing this information; it's very interesting and helpful.
I couldn't find this information in the official documentation of Houdini Engine, which states that we can split the creation of Material Instances using "unreal_split_attr." I believe it would be beneficial for others to have this information in the official documentation.
I'm currently facing a small problem that I don't know how to solve regarding material instance creation. I was wondering if you could help me find the answer.
For example, if we want to create multiple material instances referencing one master material in Unreal Engine, how can we achieve that? Currently, I haven't found any information about it. It would be great if we could control the name of the newly created material instance.
In my project, I attempted to create multiple material instances based on one master material in UE and drive the MI parameters with "unreal_material_parameter_," but I wasn't successful. My system only created one MI using the first input value of the "unreal_material_parameter_*" attribute. You can read more about this problem here: Link to the problem: https://www.sidefx.com/forum/topic/90285/?page=1#post-393138. [www.sidefx.com]
I also tried to use the information you provided with "s@unreal_split_attr = 'unreal_material_instance'", and it worked for two different master materials. However, when I tried to use "name," "unreal_material_parameter_BC," and "unreal_material_parameter," it didn't work.
Thank you for your attention, and I hope you can help me find the answer.
-
- sniegockiszymon
- Member
- 67 posts
- Joined: June 2022
- Offline
-
- Quick Links