Terrain baseTex support multiple formats

DDS, PNG, JPG or NONE
This commit is contained in:
LukasPJ 2014-09-23 07:49:27 +02:00
parent f2a3a1e2a6
commit 431d8a9b66
3 changed files with 44 additions and 8 deletions

View file

@ -74,6 +74,26 @@ protected:
NextFreeMask = Parent::NextFreeMask << 6,
};
enum BaseTexFormat
{
NONE, DDS, PNG, JPG
};
static const char* formatToExtension(BaseTexFormat format)
{
switch (format)
{
case DDS:
return "dds";
case PNG:
return "png";
case JPG:
return "jpg";
default:
return "";
}
};
Box3F mBounds;
///
@ -132,6 +152,8 @@ protected:
/// The desired size for the base texture.
U32 mBaseTexSize;
BaseTexFormat mBaseTexFormat;
///
TerrCell *mCell;