NegInfinity / ProjectExodus

Project Exodus - Unity to Unreal scene/project transfer tool.
BSD 3-Clause "New" or "Revised" License
500 stars 99 forks source link

How to use a roughtness texture? #35

Open Neogene opened 4 years ago

Neogene commented 4 years ago

Hi,

i have a shader which uses roughtness texture how can i modify the base unreal shader (exodusmaterialfunction) to use it, i tried adding a texture props but was unable to find the connection to make it work inside the smoothness/roughtness area inside exodusMaterialFunction.

thanks,

NegInfinity commented 4 years ago

You are not supposed to modify exodusMaterialFunction.

Technically the shader is supposed to work as a reasonable default material when you transfer resources over from unity to unreal. And then you're supposed to replace it with your own configuration at some point...

However, if you want to keep using exodusMaterial, you can do that. In this case you'd need to follow unity convention and provide metallic/smoothness texture.

If you want to modify the shader on unreal side, while keeping most functionality, duplicate the material, disconnect "roughness" output of exodusMaterialFunction from roughness input of material output node, and add your own functionality. image

Neogene commented 4 years ago

The problem was due to the shader used which is a shader graph and was not converted, and it used roughtness texture doing the 1-value to make it smoothness as required by the main lit master node of shader graph.

Neogene commented 4 years ago

Yes i thought to disconnect the node, but i was thinking to change it a bit to keep the same original behavior. Ok i'll disconnect it. thanks.