C++ API Reference
MDrawRequestQueue Class Reference

This class defines a simple interface for a collection of MDrawRequest objects. More...

#include <MDrawRequestQueue.h>

Public Member Functions

 MDrawRequestQueue ()
 Constructor.
 
 ~MDrawRequestQueue ()
 Destructor.
 
bool isEmpty () const
 Returns true if the queu is empty. More...
 
void add (MDrawRequest &)
 Adds a draw request to the draw queue. More...
 
MDrawRequest remove ()
 Removes a draw request from the draw queue. More...
 
 MDrawRequestQueue (const MDrawRequestQueue &)
 Copy Constructor.
 
MDrawRequestQueueoperator= (const MDrawRequestQueue &)
 Assignment operator.
 

Static Public Member Functions

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

Detailed Description

This class defines a simple interface for a collection of MDrawRequest objects.

An MDrawRequestQueue object is passed to the getDrawRequests method of a user defined shape's UI class (MPxSurfaceShapeUI). This queue keeps track of all the things that need to get draw when a refresh of the view occurs.

Maya will call the getDrawRequest methods of all the visible DAG objects before a refresh happens. Then as the refresh happens, each draw request will be processed and the corresponding draw method for each DAG object will get called. For user defined shapes MPxSurfaceShapeUI::draw will get called.

This method is obsolete. [from before Maya 2016]

Deprecated:
Use MHWRender::MRenderItem and MHWRender::MPxGeometryOverride instead for Viewport 2.0 support.
Examples:
gpuCache/gpuCacheShapeNode.cpp, and gpuCache/gpuCacheShapeNode.h.

Member Function Documentation

bool isEmpty ( ) const

Returns true if the queu is empty.

Returns
  • true the draw queue is empty
  • false the draw queue is not empty
void add ( MDrawRequest request)

Adds a draw request to the draw queue.

Parameters
[in]requestthe draw request to add
Examples:
gpuCache/gpuCacheShapeNode.cpp.
MDrawRequest remove ( )

Removes a draw request from the draw queue.

Returns
The draw request that was removed
const char * className ( )
static

Returns the name of this class.

Returns
Name of this class.

The documentation for this class was generated from the following files: