03 March 2009, 11:39 PM
This should be (and probably is) simple, but I really I can't figure it out. I'm just trying to initialise an MDoubleArray with a Python list, normally I'd just use a list, but I need it for an API command argument so it has to be an MDoubleArray.
I thought I could just do this:
import maya.OpenMaya as om
print om.MDoubleArray([1.0, 2.0, 3.0], 3)
Or at the most this:
array = [1.0, 2.0, 3.0]
print om.MDoubleArray(array, 3)
But both throw overloaded function with wrong argument errors.