globjects::VertexArray Class Reference

`#include <globjects/include/globjects/VertexArray.h>`

Inheritance diagram for globjects::VertexArray:

## Classes

struct | MultiDrawArraysRange
struct | MultiDrawElementsBaseVertexRange
struct | MultiDrawElementsRange

## Public Types

enum | AttributeImplementation { AttributeImplementation::DirectStateAccessARB, AttributeImplementation::VertexAttribBindingARB, AttributeImplementation::Legacy }
Public Types inherited from globjects::Object
enum | NameImplementation { NameImplementation::DebugKHR, NameImplementation::Legacy }

## Public Member Functions

| VertexArray ()
virtual void | accept (ObjectVisitor &visitor) override
void | bind () const
VertexAttributeBinding * | binding (gl::GLuint bindingIndex)
const VertexAttributeBinding * | binding (gl::GLuint bindingIndex) const
void | enable (gl::GLint attributeIndex)
void | disable (gl::GLint attributeIndex)
std::vector< VertexAttributeBinding * > | bindings ()
std::vector< const VertexAttributeBinding * > | bindings () const
void | drawArrays (gl::GLenum mode, gl::GLint first, gl::GLsizei count) const
void | drawArraysInstanced (gl::GLenum mode, gl::GLint first, gl::GLsizei count, gl::GLsizei instanceCount) const
void | drawArraysInstancedBaseInstance (gl::GLenum mode, gl::GLint first, gl::GLsizei count, gl::GLsizei instanceCount, gl::GLuint baseInstance) const
void | drawArraysIndirect (gl::GLenum mode, const void *indirect=nullptr) const
void | multiDrawArrays (gl::GLenum mode, gl::GLint *first, const gl::GLsizei *count, gl::GLsizei drawCount) const
void | multiDrawArraysIndirect (gl::GLenum mode, const void *indirect, gl::GLsizei drawCount, gl::GLsizei stride) const
void | drawElements (gl::GLenum mode, gl::GLsizei count, gl::GLenum type, const void *indices=nullptr) const
void | drawElementsBaseVertex (gl::GLenum mode, gl::GLsizei count, gl::GLenum type, const void *indices, gl::GLint baseVertex) const
void | drawElementsInstanced (gl::GLenum mode, gl::GLsizei count, gl::GLenum type, const void *indices, gl::GLsizei primitiveCount) const
void | drawElementsInstancedBaseInstance (gl::GLenum mode, gl::GLsizei count, gl::GLenum type, const void *indices, gl::GLsizei instanceCount, gl::GLuint baseInstance) const
void | drawElementsInstancedBaseVertex (gl::GLenum mode, gl::GLsizei count, gl::GLenum type, const void *indices, gl::GLsizei instanceCount, gl::GLint baseVertex) const
void | drawElementsInstancedBaseVertexBaseInstance (gl::GLenum mode, gl::GLsizei count, gl::GLenum type, const void *indices, gl::GLsizei instanceCount, gl::GLint baseVertex, gl::GLuint baseInstance) const
void | multiDrawElements (gl::GLenum mode, const gl::GLsizei *count, gl::GLenum type, const void **indices, gl::GLsizei drawCount) const
void | multiDrawElementsBaseVertex (gl::GLenum mode, const gl::GLsizei *count, gl::GLenum type, const void **indices, gl::GLsizei drawCount, gl::GLint *baseVertex) const
void | multiDrawElementsIndirect (gl::GLenum mode, gl::GLenum type, const void *indirect, gl::GLsizei drawCount, gl::GLsizei stride) const
void | drawRangeElements (gl::GLenum mode, gl::GLuint start, gl::GLuint end, gl::GLsizei count, gl::GLenum type, const void *indices=nullptr) const
void | drawRangeElementsBaseVertex (gl::GLenum mode, gl::GLuint start, gl::GLuint end, gl::GLsizei count, gl::GLenum type, const void *indices, gl::GLint baseVertex) const
void | multiDrawArrays (gl::GLenum mode, const std::vector< MultiDrawArraysRange > &ranges) const
void | multiDrawElements (gl::GLenum mode, gl::GLenum type, const std::vector< MultiDrawElementsRange > &ranges) const
void | multiDrawElementsBaseVertex (gl::GLenum mode, gl::GLenum type, const std::vector< MultiDrawElementsBaseVertexRange > &ranges) const
virtual gl::GLenum | objectType () const override
Public Member Functions inherited from globjects::Object
gl::GLuint | id () const
std::string | name () const
void | setName (const std::string &name)
bool | hasName () const
bool | isDefault () const
void | detach ()
Public Member Functions inherited from globjects::Referenced
| Referenced ()
void | ref () const
void | unref () const
int | refCounter () const
Public Member Functions inherited from globjects::HeapOnly
| HeapOnly ()
void | destroy () const

## Static Public Member Functions

static void | hintAttributeImplementation (AttributeImplementation impl)
static VertexArray * | fromId (gl::GLuint id)
static VertexArray * | defaultVAO ()
static void | unbind ()
Static Public Member Functions inherited from globjects::Object
static void | hintNameImplementation (NameImplementation impl)

## Protected Member Functions

| VertexArray (IDResource *resource)
virtual | ~VertexArray ()
Protected Member Functions inherited from globjects::Object
| Object (IDResource *resource)
virtual | ~Object ()
Protected Member Functions inherited from globjects::Referenced
virtual | ~Referenced ()
Protected Member Functions inherited from globjects::HeapOnly
virtual | ~HeapOnly ()

## Protected Attributes

std::map< gl::GLuint, ref_ptr< VertexAttributeBinding > > | m_bindings
Protected Attributes inherited from globjects::Object
IDResource * | m_resource
void * | m_objectLabelState

## Member Enumeration Documentation

## AttributeImplementation

enum globjects::VertexArray::AttributeImplementation

strong

Enumerator
DirectStateAccessARB |
VertexAttribBindingARB |
Legacy |

## Constructor & Destructor Documentation

## VertexArray() [1/2]

globjects::VertexArray::VertexArray | ( |  | ) |

## VertexArray() [2/2]

globjects::VertexArray::VertexArray | ( | IDResource * | resource | ) |

protected

## ~VertexArray()

virtual globjects::VertexArray::~VertexArray | ( |  | ) |

protected virtual

## Member Function Documentation

## hintAttributeImplementation()

static void globjects::VertexArray::hintAttributeImplementation | ( | AttributeImplementation | impl | ) |

static

## fromId()

static VertexArray* globjects::VertexArray::fromId | ( | gl::GLuint | id | ) |

static

## defaultVAO()

static VertexArray* globjects::VertexArray::defaultVAO | ( |  | ) |

static

## accept()

virtual void globjects::VertexArray::accept | ( | ObjectVisitor & | visitor | ) |

override virtual

Implements globjects::Object.

## bind()

void globjects::VertexArray::bind | ( |  | ) | const

## unbind()

static void globjects::VertexArray::unbind | ( |  | ) |

static

## binding() [1/2]

VertexAttributeBinding* globjects::VertexArray::binding | ( | gl::GLuint | bindingIndex | ) |

## binding() [2/2]

const VertexAttributeBinding* globjects::VertexArray::binding | ( | gl::GLuint | bindingIndex | ) | const

## enable()

void globjects::VertexArray::enable | ( | gl::GLint | attributeIndex | ) |

## disable()

void globjects::VertexArray::disable | ( | gl::GLint | attributeIndex | ) |

## bindings() [1/2]

std::vector<VertexAttributeBinding *> globjects::VertexArray::bindings | ( |  | ) |

## bindings() [2/2]

std::vector<const VertexAttributeBinding *> globjects::VertexArray::bindings | ( |  | ) | const

## drawArrays()

void globjects::VertexArray::drawArrays | ( | gl::GLenum | mode,
|  | gl::GLint | first,
|  | gl::GLsizei | count
| ) |  | const

## drawArraysInstanced()

void globjects::VertexArray::drawArraysInstanced | ( | gl::GLenum | mode,
|  | gl::GLint | first,
|  | gl::GLsizei | count,
|  | gl::GLsizei | instanceCount
| ) |  | const

## drawArraysInstancedBaseInstance()

void globjects::VertexArray::drawArraysInstancedBaseInstance | ( | gl::GLenum | mode,
|  | gl::GLint | first,
|  | gl::GLsizei | count,
|  | gl::GLsizei | instanceCount,
|  | gl::GLuint | baseInstance
| ) |  | const

## drawArraysIndirect()

void globjects::VertexArray::drawArraysIndirect | ( | gl::GLenum | mode,
|  | const void * | indirect = `nullptr`
| ) |  | const

## multiDrawArrays() [1/2]

void globjects::VertexArray::multiDrawArrays | ( | gl::GLenum | mode,
|  | gl::GLint * | first,
|  | const gl::GLsizei * | count,
|  | gl::GLsizei | drawCount
| ) |  | const

## multiDrawArraysIndirect()

void globjects::VertexArray::multiDrawArraysIndirect | ( | gl::GLenum | mode,
|  | const void * | indirect,
|  | gl::GLsizei | drawCount,
|  | gl::GLsizei | stride
| ) |  | const

## drawElements()

void globjects::VertexArray::drawElements | ( | gl::GLenum | mode,
|  | gl::GLsizei | count,
|  | gl::GLenum | type,
|  | const void * | indices = `nullptr`
| ) |  | const

## drawElementsBaseVertex()

void globjects::VertexArray::drawElementsBaseVertex | ( | gl::GLenum | mode,
|  | gl::GLsizei | count,
|  | gl::GLenum | type,
|  | const void * | indices,
|  | gl::GLint | baseVertex
| ) |  | const

## drawElementsInstanced()

void globjects::VertexArray::drawElementsInstanced | ( | gl::GLenum | mode,
|  | gl::GLsizei | count,
|  | gl::GLenum | type,
|  | const void * | indices,
|  | gl::GLsizei | primitiveCount
| ) |  | const

## drawElementsInstancedBaseInstance()

void globjects::VertexArray::drawElementsInstancedBaseInstance | ( | gl::GLenum | mode,
|  | gl::GLsizei | count,
|  | gl::GLenum | type,
|  | const void * | indices,
|  | gl::GLsizei | instanceCount,
|  | gl::GLuint | baseInstance
| ) |  | const

## drawElementsInstancedBaseVertex()

void globjects::VertexArray::drawElementsInstancedBaseVertex | ( | gl::GLenum | mode,
|  | gl::GLsizei | count,
|  | gl::GLenum | type,
|  | const void * | indices,
|  | gl::GLsizei | instanceCount,
|  | gl::GLint | baseVertex
| ) |  | const

## drawElementsInstancedBaseVertexBaseInstance()

void globjects::VertexArray::drawElementsInstancedBaseVertexBaseInstance | ( | gl::GLenum | mode,
|  | gl::GLsizei | count,
|  | gl::GLenum | type,
|  | const void * | indices,
|  | gl::GLsizei | instanceCount,
|  | gl::GLint | baseVertex,
|  | gl::GLuint | baseInstance
| ) |  | const

## multiDrawElements() [1/2]

void globjects::VertexArray::multiDrawElements | ( | gl::GLenum | mode,
|  | const gl::GLsizei * | count,
|  | gl::GLenum | type,
|  | const void ** | indices,
|  | gl::GLsizei | drawCount
| ) |  | const

## multiDrawElementsBaseVertex() [1/2]

void globjects::VertexArray::multiDrawElementsBaseVertex | ( | gl::GLenum | mode,
|  | const gl::GLsizei * | count,
|  | gl::GLenum | type,
|  | const void ** | indices,
|  | gl::GLsizei | drawCount,
|  | gl::GLint * | baseVertex
| ) |  | const

## multiDrawElementsIndirect()

void globjects::VertexArray::multiDrawElementsIndirect | ( | gl::GLenum | mode,
|  | gl::GLenum | type,
|  | const void * | indirect,
|  | gl::GLsizei | drawCount,
|  | gl::GLsizei | stride
| ) |  | const

## drawRangeElements()

void globjects::VertexArray::drawRangeElements | ( | gl::GLenum | mode,
|  | gl::GLuint | start,
|  | gl::GLuint | end,
|  | gl::GLsizei | count,
|  | gl::GLenum | type,
|  | const void * | indices = `nullptr`
| ) |  | const

## drawRangeElementsBaseVertex()

void globjects::VertexArray::drawRangeElementsBaseVertex | ( | gl::GLenum | mode,
|  | gl::GLuint | start,
|  | gl::GLuint | end,
|  | gl::GLsizei | count,
|  | gl::GLenum | type,
|  | const void * | indices,
|  | gl::GLint | baseVertex
| ) |  | const

## multiDrawArrays() [2/2]

void globjects::VertexArray::multiDrawArrays | ( | gl::GLenum | mode,
|  | const std::vector< MultiDrawArraysRange > & | ranges
| ) |  | const

## multiDrawElements() [2/2]

void globjects::VertexArray::multiDrawElements | ( | gl::GLenum | mode,
|  | gl::GLenum | type,
|  | const std::vector< MultiDrawElementsRange > & | ranges
| ) |  | const

## multiDrawElementsBaseVertex() [2/2]

void globjects::VertexArray::multiDrawElementsBaseVertex | ( | gl::GLenum | mode,
|  | gl::GLenum | type,
|  | const std::vector< MultiDrawElementsBaseVertexRange > & | ranges
| ) |  | const

## objectType()

virtual gl::GLenum globjects::VertexArray::objectType | ( |  | ) | const

override virtual

Implements globjects::Object.

## Member Data Documentation

## m_bindings

std::map<gl::GLuint, ref_ptr<VertexAttributeBinding> > globjects::VertexArray::m_bindings

protected

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

- VertexArray.h