Python API 2.0 Reference
|
Public Member Functions | |
def | __init__ () |
def | addIndexBuffer () |
def | addVertexBuffer () |
def | createIndexBuffer () |
def | createVertexBuffer () |
def | deleteIndexBuffer () |
def | deleteVertexBuffer () |
def | indexBuffer () |
def | indexBufferCount () |
def | vertexBuffer () |
def | vertexBufferCount () |
Static Public Member Functions | |
def | __new__ () |
def | dataTypeString () |
def | drawModeString () |
def | primitiveString () |
def | semanticString () |
Class for working with geometric structures used to draw objects.
def OpenMayaRender.MGeometry.__init__ | ( | ) |
Initialize self. See help(type(self)) for accurate signature.
|
static |
Create and return a new object. See help(type) for accurate signature.
def OpenMayaRender.MGeometry.addIndexBuffer | ( | ) |
addIndexBuffer(MIndexBuffer) -> bool Buffers cannot be added to the same object twice.Adds a index buffer to this MGeometry object. The buffer can only be added to this object once but may be added to others.
def OpenMayaRender.MGeometry.addVertexBuffer | ( | ) |
addVertexBuffer(MVertexBuffer) -> bool Adds a vertex buffer to this MGeometry object. The buffer can only be added to this object once but may be added to others.
def OpenMayaRender.MGeometry.createIndexBuffer | ( | ) |
createIndexBuffer(int) -> MIndexBuffer Creates a index buffer which is bound to this MGeometry object and cannot be used with any other. The buffer is automatically added to the MGeometry object so there is no need to call addIndexBuffer(). See MGeometry.dataTypeString() for a list of valid data types.
def OpenMayaRender.MGeometry.createVertexBuffer | ( | ) |
createVertexBuffer(MVertexBufferDescriptor) -> MVertexBuffer Creates a vertex buffer which is bound to this MGeometry object and cannot be used with any other. The buffer is automatically added to the MGeometry object so there is no need to call addVertexBuffer().
|
static |
dataTypeString(int) -> string Get the string name (e.g. 'Unsigned Char') for the following data type values: kInvalidType Invalid element type (default value) kFloat IEEE single precision floating point kDouble IEEE double precision floating point kChar Signed char kUnsignedChar Unsigned char kInt16 Signed 16-bit integer kUnsignedInt16 Unsigned 16-bit integer kInt32 Signed 32-bit integer kUnsignedInt32 Unsigned 32-bit integer
def OpenMayaRender.MGeometry.deleteIndexBuffer | ( | ) |
deleteIndexBuffer(int) -> bool Remove a index buffer from this object. If the buffer was bound to this object (see createIndexBuffer()) then it will become inactive and any attempt to call any of its methods will result in an exception.
def OpenMayaRender.MGeometry.deleteVertexBuffer | ( | ) |
deleteVertexBuffer(int) -> bool Remove a vertex buffer from this object. If the buffer was bound to this object (see createVertexBuffer()) then it will become inactive and any attempt to call any of its methods will result in an exception.
|
static |
drawModeString(int) -> string Get the string name (e.g. 'Wireframe, Shaded, Textured') for a combination of the following draw mode values: kWireframe Draw in wireframe mode kShaded Draw in shaded mode kTextured Draw in textured mode kBoundingBox Draw in bounding box mode kSelectionOnly Draw only in selection mode The draw mode value kAll is a combination of the following modes: kWireframe, kShaded, kTextured, and kBoundingBox
def OpenMayaRender.MGeometry.indexBuffer | ( | ) |
indexBuffer(int) -> MIndexBuffer Get the index buffer stored at the given index.
def OpenMayaRender.MGeometry.indexBufferCount | ( | ) |
indexBufferCount() -> int Get the number of index buffers contained in this MGeometry object.
|
static |
primitiveString(int) -> string Get the string name (e.g. 'Triangles') for the following primitive values: kInvalidPrimitive Default value is not valid kPoints List of points kLines List of lines kLineStrip A line strip kTriangles List of triangles kTriangleStrip A triangle strip kAdjacentTriangles A list of triangle with adjacency kAdjacentTriangleStrip A triangle strip with adjacency kAdjacentLines A list of lines with adjacency kAdjacentLineStrip A line strip with adjacency kPatch A patch
|
static |
semanticString(int) -> string Get the string name (e.g. 'Color') for the following semantic values: kInvalidSemantic Invalid data type (default value) kPosition Position vector kNormal Normal vector kTexture Texture coordinate tuple kColor Color tuple kTangent Tangent vector kBitangent Bi-normal vector kTangentWithSign Tangent vector with winding order sign
def OpenMayaRender.MGeometry.vertexBuffer | ( | ) |
vertexBuffer(int) -> MVertexBuffer Get the vertex buffer stored at the given index.
def OpenMayaRender.MGeometry.vertexBufferCount | ( | ) |
vertexBufferCount() -> int Get the number of vertex buffers contained in this MGeometry object.