11 #ifndef CAFU_MATSYS_TEXTUREMAP_IMPLEMENTATION_HPP_INCLUDED
12 #define CAFU_MATSYS_TEXTUREMAP_IMPLEMENTATION_HPP_INCLUDED
15 #if defined(_WIN32) && defined(_MSC_VER)
16 #define WIN32_LEAN_AND_MEAN
22 #include "../MapComposition.hpp"
23 #include "../TextureMap.hpp"
53 enum SourceT { MC, RawPtrExt, RawPtrOwn, BitmapPtrExt, BitmapPtrOwn };
66 unsigned long InitCounter;
73 unsigned int GetSizeX();
74 unsigned int GetSizeY();
86 TextureMap2DT(
char* Data_,
unsigned long SizeX_,
unsigned long SizeY_,
char BytesPerPixel_,
bool MakePrivateCopy,
const MapCompositionT& McForFiltersAndWrapping);
99 static const GLenum CubeTargets[6];
100 static const std::string CubeSuffixes[6];
102 static std::string GetFullCubeMapString(std::string BaseString,
unsigned long SuffixNr);
104 enum SourceT { Files, RawPtrExt, RawPtrOwn, BitmapPtrExt, BitmapPtrOwn };
117 unsigned long InitCounter;
124 unsigned int GetSizeX();
125 unsigned int GetSizeY();
137 TextureMapCubeT(
char* Data_[6],
unsigned long SizeX_,
unsigned long SizeY_,
char BytesPerPixel_,
bool MakePrivateCopy,
const MapCompositionT& McForFiltersAndWrapping);
211 unsigned long MaxTextureMapSize;
GLuint GetOpenGLObject()
This function returns an OpenGL object for this texture.
Definition: TextureMapImpl.cpp:465
unsigned long GetMaxTextureSize() const
Returns the currently set maximum texture size.
Definition: TextureMapImpl.cpp:659
bool IsCreatedFromMapComp(const MapCompositionT &MC_)
Returns true if this texture was created from a map composition that was "equivalent" to MC_...
Definition: TextureMapImpl.cpp:82
virtual bool IsCreatedFromMapComp(const MapCompositionT &MC_)=0
Returns true if this texture was created from a map composition that was "equivalent" to MC_...
GLuint GetOpenGLObject()
This function returns an OpenGL object for this texture.
Definition: TextureMapImpl.cpp:148
static TextureMapManagerImplT & Get()
Get a pointer/reference to the texture-map manager singleton.
Definition: TextureMapImpl.cpp:641
This class represents a RGBA bitmap.
Definition: Bitmap.hpp:20
This is an interface to the texture-map manager.
Definition: TextureMap.hpp:38
Definition: TextureMapImpl.hpp:142
MatSys::TextureMapI * GetTextureMap2D(const MapCompositionT &MapComp)
Creates a 2D texture-map by a texture-map composition.
Definition: TextureMapImpl.cpp:665
void FreeTextureMap(MatSys::TextureMapI *TM)
Releases the texture map from the texture manager, and releases all of its resources.
Definition: TextureMapImpl.cpp:683
bool IsCreatedFromMapComp(const MapCompositionT &MC_)
Returns true if this texture was created from a map composition that was "equivalent" to MC_...
Definition: TextureMapImpl.cpp:391
This is an interface to a texture-map.
Definition: TextureMap.hpp:23
void SetMaxTextureSize(unsigned long MaxSize)
Sets the maximum side length to which textures should be scaled down before they are employed for ren...
Definition: TextureMapImpl.cpp:653
virtual GLuint GetOpenGLObject()=0
This function returns an OpenGL object for this texture.
virtual ~TextureMapImplT()
Virtual destructor.
Definition: TextureMapImpl.hpp:41
const ArrayT< TextureMapImplT * > & GetTexMapRepository() const
Returns a reference to the texture-map repository.
Definition: TextureMapImpl.hpp:195
This class represents a cube texture-map.
Definition: TextureMapImpl.hpp:92
A MapCompositionT is a description of how a SINGLE texture map image is composited from several sourc...
Definition: MapComposition.hpp:18
This class represents a 2D texture-map.
Definition: TextureMapImpl.hpp:46
TextureMap2DT * GetTextureMap2DInternal(const MapCompositionT &MapComp)
Creates a 2D texture-map by a texture-map composition.
Definition: TextureMapImpl.cpp:689
This class represents a texture-map.
Definition: TextureMapImpl.hpp:27
TextureMapCubeT * GetTextureMapCubeInternal(const MapCompositionT &MapComp)
Creates a cube texture-map by a texture-map composition.
Definition: TextureMapImpl.cpp:723