|
Python API 2.0 Reference
|
Inheritance diagram for OpenMaya.MFnNumericData:Public Member Functions | |
| def | __init__ () |
| def | create () |
| def | getData () |
| def | numericType () |
| def | setData () |
Public Member Functions inherited from OpenMaya.MFnData | |
| def | __init__ () |
Public Member Functions inherited from OpenMaya.MFnBase | |
| def | __init__ () |
| def | hasObj () |
| def | object () |
| def | setObject () |
| def | type () |
Static Public Member Functions | |
| def | __new__ () |
Static Public Member Functions inherited from OpenMaya.MFnData | |
| def | __new__ () |
Static Public Member Functions inherited from OpenMaya.MFnBase | |
| def | __new__ () |
Static Public Attributes | |
| int | kInt64 = 10 |
Numeric Types | |
| int | k2Double = 15 |
| int | k2Float = 12 |
| int | k2Int = 8 |
| int | k2Long = 8 |
| int | k2Short = 5 |
| int | k3Double = 16 |
| int | k3Float = 13 |
| int | k3Int = 9 |
| int | k3Long = 9 |
| int | k3Short = 6 |
| int | k4Double = 17 |
| int | kAddr = 18 |
| int | kBoolean = 1 |
| int | kByte = 2 |
| int | kChar = 3 |
| int | kDouble = 14 |
| int | kFloat = 11 |
| int | kInt = 7 |
| int | kInvalid = 0 |
| int | kLast = 19 |
| int | kLong = 7 |
| int | kShort = 4 |
Static Public Attributes inherited from OpenMaya.MFnData | |
| int | kAny = 24 |
| int | kFalloffFunction = 25 |
| int | kFloatArray = 8 |
| int | kMatrixArray = 12 |
| int | kComponentList = 13 |
| int | kDoubleArray = 7 |
| int | kDynArrayAttrs = 19 |
| int | kDynSweptGeometry = 20 |
| int | kIntArray = 9 |
| int | kInvalid = 0 |
| int | kLast = 26 |
| int | kLattice = 15 |
| int | kMatrix = 5 |
| int | kMesh = 14 |
| int | kNId = 23 |
| int | kNObject = 22 |
| int | kNumeric = 1 |
| int | kNurbsCurve = 16 |
| int | kNurbsSurface = 17 |
| int | kPlugin = 2 |
| int | kPluginGeometry = 3 |
| int | kPointArray = 10 |
| int | kSphere = 18 |
| int | kString = 4 |
| int | kStringArray = 6 |
| int | kSubdSurface = 21 |
| int | kVectorArray = 11 |
Function set for non-simple numeric node data. Method resolution order: - MFnNumericData - MFnData - MFnBase - builtins.object
MFnData<h2>Constructors
| Signature | Parameters | Description |
|---|---|---|
| MFnNumericData() | Default constructor. Returns a new MFnNumericData function set with no Maya object attached. | |
| MFnNumericData(object) | object - MObject | Returns a new MFnNumericData function set, with the specified Maya object attached. |
| def OpenMaya.MFnNumericData.__init__ | ( | ) |
Initialize self. See help(type(self)) for accurate signature.
|
static |
Create and return a new object. See help(type) for accurate signature.
| OpenMaya.MFnNumericData.create | ( | ) |
Creates a new numeric data object.
| Signature: | create(type) |
| Parameters: | type - Numeric Type constant |
| Returns: | MObject |
| Description: | 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.
| Signature: | getData() |
| Parameters: | |
| Returns: | list |
| Description: | 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.
| Signature: | numericType() |
| Parameters: | |
| Returns: | Numeric Type constant |
| Description: | 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. |
|
static |
| Name: | k2Double |
| Type: | int |
| Description: | Two doubles. |
|
static |
| Name: | k2Float |
| Type: | int |
| Description: | Two floats. |
|
static |
| Name: | k2Int = k2Long |
| Type: | int |
| Description: | Same as k2Long. |
|
static |
| Name: | k2Long |
| Type: | int |
| Description: | Two ints. |
|
static |
| Name: | k2Short |
| Type: | int |
| Description: | Two shorts. |
|
static |
| Name: | k3Double |
| Type: | int |
| Description: | Three doubles. |
|
static |
| Name: | k3Float |
| Type: | int |
| Description: | Three floats. |
|
static |
| Name: | k3Int = k3Long |
| Type: | int |
| Description: | Same as k3Long. |
|
static |
| Name: | k3Long |
| Type: | int |
| Description: | Three ints. |
|
static |
| Name: | k3Short |
| Type: | int |
| Description: | Three shorts. |
|
static |
| Name: | k4Double |
| Type: | int |
| Description: | Four doubles. |
|
static |
| Name: | kAddr |
| Type: | int |
| Description: | An address/pointer. |
|
static |
| Name: | kBoolean |
| Type: | int |
| Description: | Boolean. |
|
static |
| Name: | kByte |
| Type: | int |
| Description: | One byte. |
|
static |
| Name: | kChar |
| Type: | int |
| Description: | One character. |
|
static |
| Name: | kDouble |
| Type: | int |
| Description: | One double. |
|
static |
| Name: | kFloat |
| Type: | int |
| Description: | One float. |
|
static |
| Name: | kInt = kLong |
| Type: | int |
| Description: | Same as kLong. |
|
static |
| Name: | kInvalid |
| Type: | int |
| Description: | Invalid data. |
|
static |
| Name: | kLast |
| Type: | int |
| Description: | Last value. Used for counting. |
|
static |
| Name: | kLong |
| Type: | int |
| Description: | One int. |
|
static |
| Name: | kShort |
| Type: | int |
| Description: | One short. |