This class represents a texture. More...
#include <Texture.hpp>
| Public Member Functions | |
| Texture & | operator= (const Texture &other) | 
| void | save () | 
| Writes the texture to an image file.  More... | |
| Texture () | |
| Constructor.  More... | |
| Texture (const Texture &other) | |
| Constructor.  More... | |
| Texture (int index, GlTexture *oldTexture) | |
| Constructor.  More... | |
| Texture (int index, unsigned short int width, unsigned short int height, unsigned char numChannels, unsigned char numBytesPerChan, float texelSize, unsigned char *data=nullptr) | |
| Constructor.  More... | |
| Texture (Texture &&other) | |
| Constructor.  More... | |
| virtual | ~Texture () | 
| Destructor.  More... | |
| Public Attributes | |
| unsigned char * | m_data | 
| The texture data.  More... | |
| unsigned short int | m_height | 
| int | m_index | 
| Texture index.  More... | |
| unsigned char | m_numBytesPerChan | 
| The number of bytes per channel.  More... | |
| unsigned char | m_numChannels | 
| The number of color channels.  More... | |
| float | m_texelSize | 
| The size of a texture pixel.  More... | |
| unsigned short int | m_width | 
| The dimensions of the texture.  More... | |
This class represents a texture.
Definition at line 54 of file Texture.hpp.
| lvr2::Texture::Texture | ( | ) | 
Constructor.
Definition at line 43 of file Texture.cpp.
| lvr2::Texture::Texture | ( | int | index, | 
| unsigned short int | width, | ||
| unsigned short int | height, | ||
| unsigned char | numChannels, | ||
| unsigned char | numBytesPerChan, | ||
| float | texelSize, | ||
| unsigned char * | data = nullptr | ||
| ) | 
Constructor.
Definition at line 75 of file Texture.cpp.
| lvr2::Texture::Texture | ( | int | index, | 
| GlTexture * | oldTexture | ||
| ) | 
Constructor.
Definition at line 156 of file Texture.cpp.
| lvr2::Texture::Texture | ( | Texture && | other | ) | 
Constructor.
Definition at line 98 of file Texture.cpp.
| lvr2::Texture::Texture | ( | const Texture & | other | ) | 
Constructor.
Definition at line 114 of file Texture.cpp.
| 
 | virtual | 
Destructor.
Definition at line 186 of file Texture.cpp.
Definition at line 130 of file Texture.cpp.
| void lvr2::Texture::save | ( | ) | 
Writes the texture to an image file.
The file name will be texture_<INDEX>.ppm and the used file format is Portable Pixel Map (ppm).
Definition at line 175 of file Texture.cpp.
| unsigned char* lvr2::Texture::m_data | 
The texture data.
Definition at line 114 of file Texture.hpp.
| unsigned short int lvr2::Texture::m_height | 
Definition at line 111 of file Texture.hpp.
| int lvr2::Texture::m_index | 
Texture index.
Definition at line 108 of file Texture.hpp.
| unsigned char lvr2::Texture::m_numBytesPerChan | 
The number of bytes per channel.
Definition at line 120 of file Texture.hpp.
| unsigned char lvr2::Texture::m_numChannels | 
The number of color channels.
Definition at line 117 of file Texture.hpp.
| float lvr2::Texture::m_texelSize | 
The size of a texture pixel.
Definition at line 123 of file Texture.hpp.
| unsigned short int lvr2::Texture::m_width | 
The dimensions of the texture.
Definition at line 111 of file Texture.hpp.