|
Visual Computing Library
devel
|
The Uniform class wraps a bgfx::UniformHandle and provides a simple interface to set the uniform data. More...
#include <vclib/bgfx/uniform.h>
Public Member Functions | |
| void | bind (const void *data) const |
| bgfx::UniformHandle | handle () const |
| const std::string & | name () const |
| Uniform & | operator= (Uniform oth) |
| void | swap (Uniform &oth) |
| bgfx::UniformType::Enum | type () const |
| Uniform (const std::string &name, bgfx::UniformType::Enum type) | |
| Uniform (const Uniform &oth) | |
| Uniform (Uniform &&oth) | |
Static Public Member Functions | |
| static uint | floatToUintBits (float f) |
| static float | uintBitsToFloat (uint bits) |
Private Attributes | |
| bgfx::UniformHandle | mUniformHandle = BGFX_INVALID_HANDLE |
| std::string | mUniformName |
| bgfx::UniformType::Enum | mUniformType = bgfx::UniformType::Count |
Friends | |
| void | swap (Uniform &a, Uniform &b) |
The Uniform class wraps a bgfx::UniformHandle and provides a simple interface to set the uniform data.
It manages the lifetime of the bgfx::UniformHandle: each instance of this class creates a new bgfx::UniformHandle and destroys it when the instance goes out of scope.