Map Cubic Projection of object down to UVs with IDM_ASSIGN_UVW
-
Im assiging UVs in Script,
and have the problem that i dont seem to be able to convert a CUBIC_PROJEKTION on a object down into UVs that would persist outside of the Cinema4D format.My collague gave me the advice to perform the equivalent to Assign_UVS in code and i researched and found the command IDM_ASSIGN_UVW in C4D_Symbols.h but it has no Numbercode to call mapped to it.
How do i call this command in scfript?
I know of GENERATE_UV_COORDS with 12235. But thisdoc.SetActiveObject(obj) c4d.CallCommand(CMD.GENERATE_UV_COORDS, CMD.GENERATE_UV_COORDS) # Generate UV Coordinates
does not "bake" the CUBIC projection down.
-
We life and learn.
Turns out one must select the material tag withdoc.SetActiveTag(textureTag)
before calling the command
c4d.CallCommand(CMD.GENERATE_UV_COORDS, CMD.GENERATE_UV_COORDS)
to bake the projection down, down into the ground. It now works as intended.