Hello,
I have imported over 1000 FBX models, each has a base color texture. On import, UE5 automatically creates a material and adds the image texture to the base color of each material and automatically assigns it to the corresponding model. How would I go about changing the rougness to 1 for each of the 1000 materials that gets created?
I saw the option for ‘import as material instance’ when i import assets… but it dosent do anything.
Probably the only way would be to export the materials to the gl Transmission format .gltf
Modify them all with a custom tool that would change roughness parameter via regex and save the file.
Or you could also export out all materials and try replacing all text strings in the files "roughnessFactor": 0.5
with "roughnessFactor": 1.0
for instance with a text editor like notepad++
Once all of the files were edited you would have to reimport them into unreal
example part of a file with parameter roughnessFactor:
The only down side to this method is that once you import a gltf file it will add a material expression to translate it back to a normal material. Perhaps there are other importers for unreal that clean this up.
there is a Set Material Instance Scalar Parameter value function that you could use. For example make a loop to load all material instance in a folder and change one of their parameter.
Note it works on material instance and they all have to have the same parameter name else it makes the iteration useless.