Om  1.0.0
A universal framework for multimedia simulation
Public Types | Public Member Functions | List of all members
om::graphics::buffers::BufferAccessType Class Reference

A class that specifies the allowed type of access to a Buffer. More...

#include <omGraphicsBufferAccessType.h>

Public Types

enum  Enum { READ = (1 << 0), WRITE = (1 << 1), READ_WRITE = READ | WRITE }
 An enum type that specifies the type of Buffer access. More...
 

Public Member Functions

 BufferAccessType (Enum newAccessType)
 Create a new hardware attribute buffer access type with the specified access type enum value. More...
 
Bool canRead () const
 Return whether or not this access type object allows read access to a buffer. More...
 
Bool canWrite () const
 Return whether or not this access type object allows write access to a buffer. More...
 
 operator Enum () const
 Convert this hardware attribute buffer access type to an enum value. More...
 
String toString () const
 Return a string representation of the hardware attribute buffer access type. More...
 
 operator String () const
 Convert this hardware attribute buffer access type into a string representation. More...
 

Detailed Description

A class that specifies the allowed type of access to a Buffer.

An instance of this class is used as a hint to the GPU indicating how a Buffer can be accessed. For instance, READ access allows the GPU to continue to use the buffer for rendering when it is being accessed. It is best to specify the minimum necessary access privilages, only use READ or WRITE access unless you need to read from and write to the buffer simultaneously.

Member Enumeration Documentation

An enum type that specifies the type of Buffer access.

Enumerator
READ 

An access type which allows read-only access to a Buffer.

WRITE 

An access type which allows write-only access to a Buffer.

READ_WRITE 

An access type which allows read and write access to a Buffer.

Constructor & Destructor Documentation

om::graphics::buffers::BufferAccessType::BufferAccessType ( Enum  newAccessType)
inline

Create a new hardware attribute buffer access type with the specified access type enum value.

Member Function Documentation

Bool om::graphics::buffers::BufferAccessType::canRead ( ) const
inline

Return whether or not this access type object allows read access to a buffer.

Bool om::graphics::buffers::BufferAccessType::canWrite ( ) const
inline

Return whether or not this access type object allows write access to a buffer.

om::graphics::buffers::BufferAccessType::operator Enum ( ) const
inline

Convert this hardware attribute buffer access type to an enum value.

String om::graphics::buffers::BufferAccessType::toString ( ) const

Return a string representation of the hardware attribute buffer access type.

om::graphics::buffers::BufferAccessType::operator String ( ) const
inline

Convert this hardware attribute buffer access type into a string representation.


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