The Maxon SDK Team is currently short staffed due to the winter holidays. No forum support is being provided between 15/12/2025 and 5/1/2026. For details see Maxon SDK 2025 Winter Holidays.
Python missing ObjectColorProperties?
-
The C++ SDK does have
BaseObject::GetColorPropertiesto obtain the custom displaycolor assigned to an object. This seems not to be available in the Python SDK. -
You can go directly through the properties, e.g.
import c4d def main(): selectlist = doc.GetSelection() for obj in selectlist: print obj.GetName(), " ", obj[c4d.ID_BASEOBJECT_COLOR] obj[c4d.ID_BASEOBJECT_USECOLOR] = True obj[c4d.ID_BASEOBJECT_COLOR] = c4d.Vector(0,0,1) obj.Message(c4d.MSG_UPDATE) c4d.EventAdd() if __name__=='__main__': main()So you don't need specific functions.
-
@cairyn
You are right.
I thought having to go over the BaseContainer obtained from the object viaGetData(), but didn't see anything in its content related to the displaycolor ... didn't think of just accessing the object's properties directly. I am not that confident with the Python SDK.
Thanks for the piece of code.