MaxwellMayaExtensionInfo class
Description
This class allows you to retrieve information about a given extension. Instances of this class are obtained by calling MaxwellMayaAPI::GetExtensionInfo
.
Methods
ExtensionType | GetType() const |
MString | GetName() const |
unsigned int | GetNumParams() const |
MString | GetParamName(unsigned int index) const |
ParamType | GetParamType(unsigned int index) const |
bool | GetParamDefaultAndLimits(unsigned int index, void* defaultValue, void* min, void* max) const |
static const char* | GetExtensionTypeName(ExtensionType type) |
static const char* | GetParamTypeName(ParamType type) |
ExtensionType GetType() const
Returns the type of the extension as one of:
ExtensionType_Texture
: procedural texture. Not supported by the rest of the API yet.ExtensionType_GeometryModifier
: geometry modifier. UseMaxwellMayaMesh::AddGeometryModifier
to apply modifiers to meshes.ExtensionType_GeometryLoader
: geometry loader. UseÂMaxwellMayaAPI::CreateExtensionShape
 to create objects of this type andÂMaxwellMayaExtensionShape
 to manipulate them.ExtensionType_GeometryProcedural
: procedural object. UseÂMaxwellMayaAPI::CreateExtensionShape
 to create objects of this type andÂMaxwellMayaExtensionShape
 to manipulate them.ExtensionType_Sky
: sky extension. UseMaxwellMayaAPI::AddSkyExtension
to apply a sky extension to the scene.ExtensionType_SceneModifier
: scene modifier. UseÂMaxwellMayaAPI::AddSceneModifierExtension
to add extensions of this type to the scene.
MString GetName() const
Returns the name of the extension.
unsigned int GetNumParams() const
Returns the number of parameters defined by the extension.
This method does not exist in Python. It is replaced by GetParameters
, which returns a list of all the parameters defined by the extension. For each parameter, the list contains a 5-tuple with the following values: name, type, default value, minimum value, maximum value. If the default, minimum or maximum are not defined, they are None
.
MString GetParamName(unsigned int index) const
Returns the name of the parameter at the given index. This method does not exist in Python, where it is replaced by GetParameters
(described above).
ParamType GetParamType(unsigned int index) const
Returns the type of the parameter at the given index as one of:
ParamType_Byte
ParamType_Int
ParamType_UInt
ParamType_Float
ParamType_Double
ParamType_String
ParamType_ByteArray
ParamType_IntArray
ParamType_FloatArray
ParamType_DoubleArray
This method does not exist in Python, where it is replaced by GetParameters
 (described above).
bool GetParamDefaultAndLimits(unsigned int index, void* defaultValue, void* min, void* max) const
Returns the default, minimum and maximum value for the parameter at the given index. The defaultValue, min and max arguments must point to variables of the appropriate type: unsigned char, int, unsigned int, float or double. String and array attributes do not have default and limit values; the method will return false if called for attributes of those types.
This method does not exist in Python, where it is replaced by GetParameters
 (described above).
static const char* GetExtensionTypeName(ExtensionType type)
Returns a human-readable name for the given extension type code.
static const char* GetParamTypeName(ParamType type)
Returns a human-readable name for the given parameter type code.