7 #ifndef CAFU_SCENEGRAPH_SHLMAP_MANAGER_HPP_INCLUDED
8 #define CAFU_SCENEGRAPH_SHLMAP_MANAGER_HPP_INCLUDED
10 #include "Templates/Array.hpp"
29 static const unsigned long SIZE_S;
30 static const unsigned long SIZE_T;
67 bool Allocate(
unsigned long SizeS,
unsigned long SizeT,
unsigned long& BitmapNr,
unsigned long& PosS,
unsigned long& PosT);
88 unsigned long SHLRepresentativesTexWidth;
96 bool AllocateHelper(
unsigned long SizeS,
unsigned long SizeT,
unsigned long& PosS,
unsigned long& PosT);
ArrayT< ArrayT< MatSys::TextureMapI * > > SHLMapTextures
For uncompressed SHL coeffs, for each SHLMap we store an array of texture objects, where each texture contains four SHL coeffs (in its RGBA components).
Definition: SHLMapMan.hpp:83
This class manages SHL maps, e.g. by "allocating" rectangular areas in larger coefficient maps...
Definition: SHLMapMan.hpp:25
SHLMapManT()
The constructor.
Definition: SHLMapMan.cpp:40
void ReadSHLCoeffsTable(std::istream &InFile)
Reads the lookup-table the indices are referring to (nothing is written when NrOfRepres==0 (uncompres...
Definition: SHLMapMan.cpp:70
void WriteSHLCoeffsTable(std::ostream &OutFile) const
Write the lookup-table the indices are referring to (nothing is written when NrOfRepres==0 (uncompres...
Definition: SHLMapMan.cpp:83
~SHLMapManT()
The destructor.
Definition: SHLMapMan.cpp:49
ArrayT< float > Coeffs
This should actually be ArrayT< ArrayT<float> > Coeffs; that is, for each SHLMap element, store an array of coefficients.
Definition: SHLMapMan.hpp:43
static char NrOfBands
Number n of bands for which we have computed and stored coefficients (n^2 many).
Definition: SHLMapMan.hpp:32
Definition: SHLMapMan.hpp:35
ArrayT< float > SHLCoeffsTable
The lookup-table of representatives (NrOfRepres * (NrOfBands^2) many) the SHLMaps::Indices refer to...
Definition: SHLMapMan.hpp:74
This is an interface to a texture-map.
Definition: TextureMap.hpp:23
static unsigned int NrOfRepres
Number of representatives of SH vectors. If >0, the SHL coeffs are compressed, uncompressed otherwise...
Definition: SHLMapMan.hpp:33
bool Allocate(unsigned long SizeS, unsigned long SizeT, unsigned long &BitmapNr, unsigned long &PosS, unsigned long &PosT)
Finds a position for a rectangular SHLMap within SHLMaps[SHLMaps.Size()-1].Coeff. ...
Definition: SHLMapMan.cpp:90
SHLMapT()
Constructor.
Definition: SHLMapMan.cpp:21
void InitTextures()
Initializes the MatSys textures.
Definition: SHLMapMan.cpp:109
ArrayT< unsigned short > Indices
For compressed SHL coeffs, this array contains the index for each map element into the bigger lookup-...
Definition: SHLMapMan.hpp:47