Hey there! I am tasked with writing a python script for automated object baking.I am stuck after importing the model. Only the albedo map is assigned to the material.Maps like metallic, normal and roughness are not assigned. It would be no problem for me to assign those texures in the python script but i haven't found any…
Hey. There are two examples in plugin folder that can help you with materials scripting: Creating Materials from Images.py Editing Materials.py Shortly: # Create new material mat = mset.Material(name) # Delete it mat.destroy() # Assign material to mesh mat.assign(mesh) # Assign texture to material, where texture - path to…
thanks @ryanroye for linking me to this thread. I spoke with a tech artist friend and he came up with the exact code you have to set the Albedo map to sRGB: material.albedo.getField("Albedo Map").sRGB = True I ran into the same UI issues. I didn't try save/reloading. But it was not keeping my sRGB checked sometimes. It…
I got some help from Luxary (author of this script for Marmoset Toolbag), as I noticed their plugin affected the things I wanted to change. To save others the same frustration, I will relay the info I received from them here. Example of setting the Albedo Map to use sRGB, and not use mipmaps.…