Creates a new numeric data object of the given type, attaches it to the function set and returns an MObject which references it. Only the multi-value numeric types (e.g. k2Short, k3Short) are accepted. Single-value numeric types (e.g. kShort) can be accessed directly through MPlug and MDataHandle and thus do not require a data object to encapsulate them.
OpenMaya.MFnNumericData.getData
(
)
Returns a list containing the attached data object's data.
Returns a list containing the encapsulated numeric data's elements. k*Short, k*Int and k*Long types will be returned as Python integers. k*Float and k*Double types will be returned as Python floats.
OpenMaya.MFnNumericData.numericType
(
)
Returns the type of data in the attached data object.
Returns the type of numeric data in the object currently attached to the function set.
OpenMaya.MFnNumericData.setData
(
)
Sets the value of the data in the attached data object.
Signature:
setData(seq)
Parameters:
seq - sequence of data values
Returns:
Reference to self.
Description:
Replaces the encapsulated data with the elements of the supplied sequence. k*Short, k*Int and k*Long types will accept sequences of Python integers. k*Float and k*Double types will accept sequences of Python floats, integers or a mix of the two. If the sequence contains the wrong number or type of elements then a TypeError will be raised.