OpenMaya.MPxData Class Reference

Class Description

Base Class for User-defined Dependency Graph Data Types.
+ Inheritance diagram for OpenMaya.MPxData:

Public Member Functions

__init__ ()
 
copy ()
 
name ()
 
readASCII ()
 
readBinary ()
 
typeId ()
 
writeASCII ()
 
writeBinary ()
 

Static Public Attributes

int kData = 0
 
int kGeometryData = 1
 
int kLast = 2
 

Constructor & Destructor Documentation

OpenMaya.MPxData.__init__ ( )
x.__init__(...) initializes x; see help(type(x)) for signature

Member Function Documentation

OpenMaya.MPxData.copy ( )
copy(src) -> self

This method initializes an instance of an MPxData derived class from another existing instance.  This method can be thought of as the second half of a copy constructor for the class.  The default constructor has already been called for the instance, and this method is used to set the private data by copying the values from an existing instance.
This method must be implemented by the derived class.

* src (MPxData) - The object from which to copy the private data
OpenMaya.MPxData.name ( )
name() -> string

Returns the name of the custom data type.
This method must be implemented by the derived class.
OpenMaya.MPxData.readASCII ( )
readASCII(argList, endOfTheLastParsedElement) -> int

Creates Data in Data Block as specified by input from ASCII file record.
Returns the new last argument parsed by this method.

* argList (MArgList) - List of arguments read from ASCII record* endOfTheLastParsedElement (int) - points to last argument already parsed.
OpenMaya.MPxData.readBinary ( )
readBinary(in, length) -> int

Creates Data in Data Block as specified by binary data from the given stream.
Returns the numbers of data bytes processed.

* in (bytearray) - Input stream
* length (int) - Length in bytes of binary data to be read.
OpenMaya.MPxData.typeId ( )
typeId() -> MTypeId

Determines the type id of the Data object.
This method must be implemented by the derived class.
OpenMaya.MPxData.writeASCII ( )
writeASCII() -> string

Encodes Data in accordance with the ASCII file format and returns as string.
OpenMaya.MPxData.writeBinary ( )
writeBinary() -> bytearray

Encodes Data in accordance with the binary file format and returns as bytearray.