#include <TextureContainer.h>
Inheritance diagram for OpenGL::TextureContainer:
Public Types | |
enum | Channel { , GREEN, BLUE, ALPHA } |
Public Member Functions | |
TextureContainer (IoTextureSet *textureSet, unsigned int viewportX, unsigned int viewportY, unsigned int viewportWidth, unsigned int viewportHeight) | |
TextureContainer (IoTextureSet *textureSet) | |
void | render () const |
unsigned int | getTextureCount () const |
bool | isActive (unsigned int textureNumber) const |
void | activateTexture (unsigned int textureNumber) |
void | deactivateTexture (unsigned int textureNumber) |
void | dumpTexture (unsigned int textureNumber, Channel channel, std::ostream &output) |
unsigned int | getTextureId (unsigned int textureNumber) |
void | activateSingleChannel (Channel channel) |
void | activateDualChannels (Channel first, Channel second) |
void | activateTripleChannels (Channel first, Channel second, Channel third) |
void | setRange (float minValue, float maxValue) |
bool | isGridActive () const |
void | setGridActive (bool gridActive) |
void | setTextColor (float red, float green, float blue) |
void | setGridColor (float red, float green, float blue) |
void | setSeparatorColor (float red, float green, float blue) |
void | setDescription (const std::string &description) |
Static Public Member Functions | |
static bool | getSmoothDisplay () |
static void | setSmoothDisplay (bool smoothDisplay) |
Protected Member Functions | |
void | insertTexture (unsigned int textureId) |
Private Member Functions | |
virtual GLenum | getActiveTarget () const =0 |
virtual unsigned int | getActiveWidth () const =0 |
virtual unsigned int | getActiveHeight () const =0 |
virtual GLenum | getTarget (unsigned int textureNumber) const =0 |
virtual unsigned int | getWidth (unsigned int textureNumber) const =0 |
virtual unsigned int | getHeight (unsigned int textureNumber) const =0 |
virtual void | handleTextureActivation (unsigned int textureNumber)=0 |
|
Texture channels. |
|
Initializes the TextureContainer based on the given IoTextureSet and viewport dimensions.
|
|
Initializes the TextureContainer based on the given IoTextureSet, and the current OpenGL viewport coordinates.
|
|
Activates two channels of the textures. The first channel becomes the red channel of the output, whereas the second channel becomes the green channel of the output.
|
|
Activates a single channel of the textures. This channel will be displayed in grayscale.
|
|
Activates the given texture.
|
|
Activates three channels of the textures. The first channel becomes the red channel of the output, the second channel becomes the green channel of the output, and the third channel becomes the blue channel of the output.
|
|
Deactivates the given texture.
|
|
Dumps the selected channel of the given texture to the output stream.
|
|
Gets the height of the active texture(s).
Implemented in OpenGL::PrimaryTextureContainer, and OpenGL::SecondaryTextureContainer. |
|
Gets the texture target of the active texture(s).
Implemented in OpenGL::PrimaryTextureContainer, and OpenGL::SecondaryTextureContainer. |
|
Gets the width of the active texture(s).
Implemented in OpenGL::PrimaryTextureContainer, and OpenGL::SecondaryTextureContainer. |
|
Gets the height of the given texture.
Implemented in OpenGL::PrimaryTextureContainer, and OpenGL::SecondaryTextureContainer. |
|
Checks whether interpolation is used when displaying the active textures.
|
|
Gets the texture target of the given texture.
Implemented in OpenGL::PrimaryTextureContainer, and OpenGL::SecondaryTextureContainer. |
|
Gets the number of textures in the TextureContainer. The textures in the TextureContainer are numbered from 0 to number of textures - 1.
|
|
Gets the OpenGL texture identifier (GLuint) of the given texture.
|
|
Gets the width of the given texture.
Implemented in OpenGL::PrimaryTextureContainer, and OpenGL::SecondaryTextureContainer. |
|
Called whenever the given texture is activated.
Implemented in OpenGL::PrimaryTextureContainer, and OpenGL::SecondaryTextureContainer. |
|
Used by subclasses to insert textures.
|
|
Checks if the given texture is active.
|
|
Checks if the texture grid is currently active. The texture grid is drawn on top of each active texture, separating the texture texels.
|
|
Renders the currently active textures to the viewport, based on the selected channels, range and colors. |
|
Set the texture container's description, displayed when render is called.
|
|
Sets the active status of the texture grid.
|
|
Sets the texture grid color used when drawing the texture grid on top of each active texture, separating the texture texels.
|
|
Sets the range of values to be displayed. Values below minValue will become 0, whereas values above maxValue become 1.
|
|
Sets the separator color used when drawing a frame around each active texture.
|
|
Sets whether interpolation should be used when displaying the active textures.
|
|
Sets the text color used when displaying texture descriptions.
|