MPxIndexBufferMutator Class Reference

This reference page is linked to from the following overview topics: Extension for Autodesk Maya 2013, 4.3 Customizing Geometric Data for Shaders.



Detailed Description

Base class for user defined index buffer mutators.

Implementations of MPxIndexBufferMutator must be registered with Maya through MDrawRegistry.

MPxIndexBufferMutators are registered with a unique mutator type name. The name signifies the name of the custom index buffer the mutator can produce. When an MPxShaderOverride or custom renderer uses an effect with custom index buffer mutator they can provide a MIndexBufferDescriptor with the desired mutator name. A registered MPxIndexBufferMutator will be used to mutate the existing index buffer.

#include <MPxIndexBufferMutator.h>

List of all members.

Public Member Functions

 MPxIndexBufferMutator ()
 Construct a MPxIndexBufferMutator.
virtual ~MPxIndexBufferMutator ()
 Destructor.
virtual MGeometry::Primitive mutateIndexing (const MHWRender::MComponentDataIndexingList &sourceIndexBuffers, const MVertexBufferArray &vertexBuffers, MIndexBuffer &indexBuffer, int &primitiveStride) const =0
 This method gets called to allow the generator to mutate the data for a custom index stream using information stored in the vertex buffers.

Static Public Member Functions

static const char * className ()
 Returns the name of this class.

Member Function Documentation

MGeometry::Primitive mutateIndexing ( const MHWRender::MComponentDataIndexingList sourceIndexBuffers,
const MVertexBufferArray vertexBuffers,
MIndexBuffer indexBuffer,
int &  primitiveStride 
) const [pure virtual]

This method gets called to allow the generator to mutate the data for a custom index stream using information stored in the vertex buffers.

Parameters:
[in]sourceIndexBuffersCurrent values for the index buffers.
[in]vertexBuffersAll vertex buffers generated for this primitive.
[out]indexBufferThe index buffer to fill.
[out]primitiveStrideThe stride of the generated indexing, only valid when the returned primitive type is kPatch.
Returns:
The type of primitive of the generated indexing.
const char * className ( ) [static]

Returns the name of this class.

Returns:
Name of this class.

MPxIndexBufferMutator MPxIndexBufferMutator MPxIndexBufferMutator MPxIndexBufferMutator MPxIndexBufferMutator MPxIndexBufferMutator MPxIndexBufferMutator MPxIndexBufferMutator MPxIndexBufferMutator MPxIndexBufferMutator
MPxIndexBufferMutator MPxIndexBufferMutator MPxIndexBufferMutator MPxIndexBufferMutator MPxIndexBufferMutator MPxIndexBufferMutator MPxIndexBufferMutator MPxIndexBufferMutator MPxIndexBufferMutator MPxIndexBufferMutator