50 #ifndef TEXTUREDATA_HH 51 #define TEXTUREDATA_HH 54 #include "TextureParameters.hh" 57 #include <QStringList> 58 #include <ACG/GL/gl.hh> 64 enum TextureType { UNSET = 1 << 0,
68 HALFEDGEBASED = 1 << 2,
72 MULTITEXTURE = 1 << 4 };
98 void filename( QString _name ) {
filename_ = _name; };
102 void id(
int _id ) {
id_ = _id; };
103 int id() {
return id_; };
106 void glName( GLuint _glName ) {
glName_ = _glName; };
107 GLuint glName() {
return glName_; };
110 void name( QString _name ) {
name_ = _name; };
111 QString name() {
return name_; };
113 void visibleName( QString _name ) {
visibleName_ = _name; };
117 void dimension( uint _dimension ) {
dimension_ = _dimension; };
121 void enabled(
bool _enabled ) {
enabled_ = _enabled; };
122 bool enabled() {
return enabled_; };
124 void disable(){
enabled_ =
false; };
126 void hidden(
bool _hidden ) {
hidden_ = _hidden; };
127 bool hidden() {
return hidden_; };
128 void hide() {
hidden_ =
true; };
130 void dirty(
bool _dirty ) {
dirty_ = _dirty; };
131 bool dirty() {
return dirty_; };
132 void clean() {
dirty_ =
false; };
133 void setDirty() {
dirty_ =
true; };
139 void type( TextureType _type ) {
type_ = _type; };
140 TextureType type( ) {
return type_; };
216 bool textureExists(QString _textureName);
220 bool isEnabled(QString _textureName);
224 bool enableTexture(QString _textureName,
bool _exclusive =
false);
227 void disableTexture(QString _textureName);
230 int addTexture ( QString _textureName , QString _filename , uint _dimension, GLuint _glName );
233 int addTexture (
Texture _texture, GLuint _glName );
236 bool addMultiTexture( QString _textureName );
239 bool setImage( QString _textureName ,
int _id );
253 Texture& texture(QString _textureName);
256 std::vector< Texture >& textures();
264 std::map< int, GLuint >* textureMap();
269 std::map< int, std::string >* propertyMap();
273 std::map< int, GLuint> textureMap_;
274 std::map< int, std::string> propertyMap_;
285 int getTextureIndex(QString _textureName);
291 #endif //TEXTUREDATA_HH int textureImageId_
The image used as the texture ( Ids are handled by the ImageStore )
QString indexMappingProperty_
bool hidden_
Hidden flag ( If this texture belongs to a multitexture, it will be hidden in the context menu ) ...
TexParameters parameters
Parameters of the texture.
int nextInternalID_
internal id for the next texture
QString visibleName_
Name visible in the gui.
QString name_
Texture Name.
bool dirty_
does this texture need an update?
virtual PerObjectData * copyPerObjectData()
Copy Function.
TextureType type_
Texture Type.
std::vector< Texture > textures_
vector containing all textures of an object
QString filename_
Filename of the texture.
QStringList multiTextureList
If this is a multiTexture, the list will contain all textures for this multi Texture node...