Carna Version 3.3.3
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | Static Public Attributes | Protected Member Functions | Related Symbols | List of all members
Carna::base::TextureBase Class Reference

Texture base class with dimension-independent definitions. More...

#include <Texture.h>

+ Inheritance diagram for Carna::base::TextureBase:

Public Member Functions

virtual ~TextureBase ()
 Deletes the maintained OpenGL texture object.
 

Public Attributes

const unsigned int id
 Holds the ID of the represented OpenGL texture object.
 

Static Public Attributes

static const unsigned int SETUP_UNIT = 0
 Texture unit that is fine to be used for temporal bindings, i.e. for setting textures up. This unit shouldn't be used for lasting bindings.
 

Protected Member Functions

 TextureBase ()
 Creates OpenGL texture object.
 
void uploadGLTextureData (const Eigen::Matrix< unsigned int, 1, 1 > &size, int internalFormat, int pixelFormat, int bufferType, const void *bufferPtr)
 Wraps glTexImage1d.
 
void uploadGLTextureData (const math::Vector2ui &size, int internalFormat, int pixelFormat, int bufferType, const void *bufferPtr)
 Wraps glTexImage2d.
 
void uploadGLTextureData (const math::Vector3ui &size, int internalFormat, int pixelFormat, int bufferType, const void *bufferPtr)
 Wraps glTexImage3d.
 

Related Symbols

(Note that these are not member symbols.)

template<unsigned int dimension>
void bindGLTextureObject (unsigned int unit, unsigned int id)
 Binds OpenGL texture object id to texture unit. For internal usage only, use Texture::bind instead.
 

Detailed Description

Texture base class with dimension-independent definitions.

Author
Leonid Kostrykin
Date
24.3.15 - 30.3.15

Definition at line 77 of file Texture.h.

Friends And Related Symbol Documentation

◆ bindGLTextureObject()

template<unsigned int dimension>
void bindGLTextureObject ( unsigned int  unit,
unsigned int  id 
)
related

Binds OpenGL texture object id to texture unit. For internal usage only, use Texture::bind instead.

Definition at line 42 of file Texture.h.

Member Data Documentation

◆ id

const unsigned int Carna::base::TextureBase::id

Holds the ID of the represented OpenGL texture object.

Definition at line 87 of file Texture.h.

◆ SETUP_UNIT

const unsigned int Carna::base::TextureBase::SETUP_UNIT = 0
static

Texture unit that is fine to be used for temporal bindings, i.e. for setting textures up. This unit shouldn't be used for lasting bindings.

Definition at line 98 of file Texture.h.


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