import maya.OpenMaya as omi
col = omi.MColor(1.0, 0.5, 0.25)
# tuple
rgb = col.r, col.g, col.b
# If you need MFloatArray
arr = omi.MFloatArray(3)
arr[0], arr[1], arr[2] = rgb
--
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_m...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/5d08ac61-058d-4575-b55f-f63fb20eaf40n%40googlegroups.com.
hi, Justin
thanks for your reply and your code , after I got someone's help , it is about the parameter pointer issues between C++ and Python, which needs MscriptUtil() to solve , the blow code works finally .
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/adc2584e-d59f-400b-8119-368b42b38e90n%40googlegroups.com.