- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Examples

- Class List
- Class Hierarchy
- Class Members

Public Member Functions | Static Public Member Functions

# MPxVertexBufferMutator Class Reference
OpenMayaRender - API module for rendering | Proxy classes

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

Search for all occurrences

## Detailed Description

Base class for user defined vertex buffer generators.

Implementations of MPxVertexBufferMutator must be registered with Maya through MDrawRegistry.

MPxVertexBufferMutators are registered with a unique buffer name. The name signifies the name of the custom stream the mutator can alter. When an MPxShaderOverride or custom renderer uses an effect with custom input streams they can provide a unique name in the MVertexBufferDescriptor and a registered MPxVertexBufferMutator will be used to alter the custom stream for a given shape using the incoming requirements held in the MVertexBuffer.

modifyVertexStream() is called to allow the mutator to alter the vertex data Access the requirements for the requested stream through vertexBuffer.descriptor(). Populate the stream using vertexBuffer.acquire() and vertexBuffer.commit().

`#include <MPxVertexBufferMutator.h>`

List of all members.

## Public Member Functions
| MPxVertexBufferMutator ()
| Construct an MPxVertexBufferMutator.
virtual | ~MPxVertexBufferMutator ()
| Destructor.
virtual void | modifyVertexStream (const MObject &object, MVertexBuffer &vertexBuffer, const MComponentDataIndexing &targetIndexing) const =0
| This method gets called to allow the mutator to alter the data for a custom vertex stream.
## Static Public Member Functions
static const char * | className ()
| Returns the name of this class.

## Member Function Documentation

void modifyVertexStream | ( | const MObject & | object,
|  | MVertexBuffer & | vertexBuffer,
|  | const MComponentDataIndexing & | targetIndexing
| ) |  | const`[pure virtual]`

Search for all occurrences

This method gets called to allow the mutator to alter the data for a custom vertex stream.

Use the requirements in the vertexBuffer to get the description of the stream. Use vertexBuffer.aquire() and vertexBuffer.commit() to fill the buffer.

Parameters:

  [in] | object | The object being evaluated.
  [in,out] | vertexBuffer | The vertex buffer to alter.
  [in] | targetIndexing | Vertex index mapping from targetIndexing.getComponentType() space to vertex buffer space.

const char * className | ( |  | ) | `[static]`

Search for all occurrences

Returns the name of this class.

Returns:
  Name of this class.

MPxVertexBufferMutator MPxVertexBufferMutator MPxVertexBufferMutator MPxVertexBufferMutator MPxVertexBufferMutator MPxVertexBufferMutator MPxVertexBufferMutator MPxVertexBufferMutator MPxVertexBufferMutator MPxVertexBufferMutator
MPxVertexBufferMutator MPxVertexBufferMutator MPxVertexBufferMutator MPxVertexBufferMutator MPxVertexBufferMutator MPxVertexBufferMutator MPxVertexBufferMutator MPxVertexBufferMutator MPxVertexBufferMutator MPxVertexBufferMutator