C++ API Reference: MAutoCLEventList Class Reference

Introduced in 2023.0 More...

#include <MOpenCLAutoPtr.h>

Public Member Functions

 MAutoCLEventList ()
 Constructs a MAutoCLEventList.
 
 MAutoCLEventList (const MAutoCLEventList &)
 Constructs a MAutoCLEventList. More...
 
 ~MAutoCLEventList ()
 Destructor.
 
void add (const MAutoCLEvent &event)
 This method adds a new event to the list. More...
 
void add (MOpenCLBuffer &buf)
 This method adds the bufferReadyEvent of a buffer to the list. More...
 
const cl_event * array () const
 This method returns the array of events contained in the MAutoCLEventList. More...
 
cl_uint size () const
 This method returns the number of events contained in the MAutoCLEventList. More...
 

Detailed Description

Introduced in 2023.0

2023.0:
Introduced in this version.

Helper class to keep track of CL events

MAutoCLEventList is a simple class to make it easier to manage an event wait list for kernels that are queued up.

Note: this was originally available in Maya 2022 as MGPUEventList in the OpenMayaAnim module. MGPUEventList is now a typedef of MAutoCLEventList.

+ Examples:

Constructor & Destructor Documentation

MAutoCLEventList ( const MAutoCLEventList other)

Constructs a MAutoCLEventList.

Parameters
[in]otherThe MAutoCLEventList to copy.

Member Function Documentation

void add ( const MAutoCLEvent event)

This method adds a new event to the list.

Parameters
[in]eventThe event to add
+ Examples:
void add ( MOpenCLBuffer buf)

This method adds the bufferReadyEvent of a buffer to the list.

Parameters
[in]bufThe buffer of which we want to add the bufferReadyEvent
const cl_event * array ( ) const

This method returns the array of events contained in the MAutoCLEventList.

Returns
the pointer to the array containing the events
+ Examples:
cl_uint size ( ) const

This method returns the number of events contained in the MAutoCLEventList.

Returns
the number of events
+ Examples:

The documentation for this class was generated from the following files:
  • MOpenCLAutoPtr.h
  • MOpenCLAutoPtr.cpp