#include <llimagedxt.h>
Inheritance diagram for LLImageDXT:


Definition at line 38 of file llimagedxt.h.
| FORMAT_UNKNOWN | |
| FORMAT_I8 | |
| FORMAT_A8 | |
| FORMAT_RGB8 | |
| FORMAT_RGBA8 | |
| FORMAT_DXT1 | |
| FORMAT_DXT2 | |
| FORMAT_DXT3 | |
| FORMAT_DXT4 | |
| FORMAT_DXT5 | |
| FORMAT_DXR1 | |
| FORMAT_DXR2 | |
| FORMAT_DXR3 | |
| FORMAT_DXR4 | |
| FORMAT_DXR5 | |
| FORMAT_NOFILE | 
Definition at line 41 of file llimagedxt.h.
| LLImageDXT::~LLImageDXT | ( | ) |  [protected] | 
Definition at line 174 of file llimagedxt.cpp.
| LLImageDXT::LLImageDXT | ( | ) | 
Definition at line 167 of file llimagedxt.cpp.
Reimplemented from LLImageFormatted.
Definition at line 460 of file llimagedxt.cpp.
References FORMAT_UNKNOWN, formatBytes(), LLImageBase::getHeight(), getMipOffset(), LLImageBase::getWidth(), llendl, llerrs, LLImageFormatted::mDiscardLevel, mFileFormat, and S32.
| void LLImageDXT::calcDiscardWidthHeight | ( | S32 | discard_level, | |
| EFileFormat | format, | |||
| S32 & | width, | |||
| S32 & | height | |||
| ) |  [static] | 
Definition at line 141 of file llimagedxt.cpp.
References checkMinWidthHeight().
Referenced by getMipData().
| S32 LLImageDXT::calcHeaderSize | ( | ) |  [virtual] | 
Reimplemented from LLImageFormatted.
Definition at line 454 of file llimagedxt.cpp.
References llmax().
Referenced by setFormat().
Definition at line 153 of file llimagedxt.cpp.
References S32.
Referenced by convertToDXR(), encode(), and getMipOffset().
| void LLImageDXT::checkMinWidthHeight | ( | EFileFormat | format, | |
| S32 & | width, | |||
| S32 & | height | |||
| ) |  [static] | 
Definition at line 36 of file llimagedxt.cpp.
References FORMAT_DXR5, FORMAT_DXT1, llmax(), and S32.
Referenced by calcDiscardWidthHeight(), encode(), and formatBytes().
| bool LLImageDXT::convertToDXR | ( | ) | 
Definition at line 403 of file llimagedxt.cpp.
References calcNumMips(), FORMAT_DXR1, FORMAT_DXR2, FORMAT_DXR3, FORMAT_DXR4, FORMAT_DXR5, FORMAT_DXT1, FORMAT_DXT2, FORMAT_DXT3, FORMAT_DXT4, FORMAT_DXT5, FORMAT_UNKNOWN, formatBytes(), LLImageDXT::dxtfile_header_t::pixel_format::fourcc, LLImageBase::getData(), LLImageBase::getDataSize(), getFourCC(), LLImageBase::getHeight(), getMipOffset(), LLImageBase::getWidth(), height, llassert, llendl, llerrs, llformat(), llwarns, mFileFormat, mHeaderSize, LLImageDXT::dxtfile_header_t::pixel_fmt, S32, LLImageFormatted::setData(), updateData(), and width.
| BOOL LLImageDXT::decode | ( | LLImageRaw * | raw_image, | |
| F32 | time = 0.0 | |||
| ) |  [virtual] | 
Implements LLImageFormatted.
Definition at line 264 of file llimagedxt.cpp.
References FALSE, FORMAT_DXR5, FORMAT_DXT1, formatBytes(), LLImageBase::getComponents(), LLImageBase::getData(), LLImageBase::getDataSize(), LLImageBase::getHeight(), getMipOffset(), LLImageBase::getWidth(), height, llassert_always, llendl, llwarns, mFileFormat, LLImageRaw::resize(), S32, LLImageBase::setLastError(), TRUE, and width.
| BOOL LLImageDXT::encode | ( | const LLImageRaw * | raw_image, | |
| F32 | time = 0.0 | |||
| ) |  [virtual] | 
| BOOL LLImageDXT::encode | ( | const LLImageRaw * | raw_image, | |
| F32 | time, | |||
| bool | explicit_mips | |||
| ) | 
Definition at line 311 of file llimagedxt.cpp.
References LLImageFormatted::allocateData(), calcNumMips(), checkMinWidthHeight(), extractMip(), format, FORMAT_A8, FORMAT_RGB8, FORMAT_RGBA8, formatBytes(), LLImageDXT::dxtfile_header_t::pixel_format::fourcc, LLImageDXT::dxtfile_header_t::fourcc, LLImageBase::generateMip(), LLImageBase::getComponents(), LLImageBase::getData(), getFourCC(), LLImageBase::getHeight(), getMipOffset(), LLImageBase::getWidth(), height, llassert, llassert_always, llendl, llerrs, LLImageDXT::dxtfile_header_t::maxheight, LLImageDXT::dxtfile_header_t::maxwidth, mFileFormat, mHeaderSize, LLImageDXT::dxtfile_header_t::num_mips, LLImageDXT::dxtfile_header_t::pixel_fmt, S32, LLImageBase::setSize(), TRUE, and width.
Referenced by encode().
| void LLImageDXT::extractMip | ( | const U8 * | indata, | |
| U8 * | mipdata, | |||
| int | width, | |||
| int | height, | |||
| int | mip_width, | |||
| int | mip_height, | |||
| EFileFormat | format | |||
| ) |  [static, private] | 
| S32 LLImageDXT::formatBits | ( | EFileFormat | format | ) |  [static] | 
Definition at line 44 of file llimagedxt.cpp.
References FORMAT_A8, FORMAT_DXR1, FORMAT_DXR3, FORMAT_DXR5, FORMAT_DXT1, FORMAT_DXT3, FORMAT_DXT5, FORMAT_I8, FORMAT_RGB8, FORMAT_RGBA8, llendl, and llerrs.
Referenced by formatBytes().
| S32 LLImageDXT::formatBytes | ( | EFileFormat | format, | |
| S32 | width, | |||
| S32 | height | |||
| ) |  [static] | 
Definition at line 65 of file llimagedxt.cpp.
References checkMinWidthHeight(), formatBits(), and S32.
Referenced by calcDataSize(), convertToDXR(), decode(), encode(), extractMip(), and getMipOffset().
| S32 LLImageDXT::formatComponents | ( | EFileFormat | format | ) |  [static] | 
Definition at line 74 of file llimagedxt.cpp.
References FORMAT_A8, FORMAT_DXR1, FORMAT_DXR3, FORMAT_DXR5, FORMAT_DXT1, FORMAT_DXT3, FORMAT_DXT5, FORMAT_I8, FORMAT_RGB8, FORMAT_RGBA8, llendl, and llerrs.
Referenced by updateData().
| static S32 LLImageDXT::formatOffset | ( | EFileFormat | format, | |
| S32 | width, | |||
| S32 | height, | |||
| S32 | max_width, | |||
| S32 | max_height | |||
| ) |  [static] | 
| EFileFormat LLImageDXT::getFileFormat | ( | ) |  [inline] | 
| LLImageDXT::EFileFormat LLImageDXT::getFormat | ( | S32 | fourcc | ) |  [static] | 
Definition at line 95 of file llimagedxt.cpp.
References FORMAT_A8, FORMAT_DXR1, FORMAT_DXR2, FORMAT_DXR3, FORMAT_DXR4, FORMAT_DXR5, FORMAT_DXT1, FORMAT_DXT2, FORMAT_DXT3, FORMAT_DXT4, FORMAT_DXT5, FORMAT_I8, FORMAT_RGB8, FORMAT_RGBA8, and FORMAT_UNKNOWN.
Referenced by updateData().
| S32 LLImageDXT::getFourCC | ( | EFileFormat | format | ) |  [static] | 
Definition at line 118 of file llimagedxt.cpp.
References FORMAT_A8, FORMAT_DXR1, FORMAT_DXR2, FORMAT_DXR3, FORMAT_DXR4, FORMAT_DXR5, FORMAT_DXT1, FORMAT_DXT2, FORMAT_DXT3, FORMAT_DXT4, FORMAT_DXT5, FORMAT_I8, FORMAT_RGB8, and FORMAT_RGBA8.
Referenced by convertToDXR(), and encode().
| BOOL LLImageDXT::getMipData | ( | LLPointer< LLImageRaw > & | raw, | |
| S32 | discard = -1 | |||
| ) | 
Definition at line 291 of file llimagedxt.cpp.
References calcDiscardWidthHeight(), LLImageBase::getComponents(), LLImageBase::getData(), getMipOffset(), height, llendl, llerrs, LLImageFormatted::mDiscardLevel, mFileFormat, S32, TRUE, and width.
Definition at line 227 of file llimagedxt.cpp.
References calcNumMips(), FORMAT_DXT1, FORMAT_DXT5, formatBytes(), LLImageBase::getHeight(), LLImageBase::getWidth(), height, llassert, llclamp(), llendl, llerrs, mFileFormat, mHeaderSize, S32, and width.
Referenced by calcDataSize(), convertToDXR(), decode(), encode(), and getMipData().
| bool LLImageDXT::isCompressed | ( | ) |  [inline] | 
| void LLImageDXT::setFormat | ( | ) | 
Definition at line 251 of file llimagedxt.cpp.
References calcHeaderSize(), FORMAT_DXR1, FORMAT_DXR3, LLImageBase::getComponents(), llendl, llerrs, mFileFormat, mHeaderSize, and S32.
| BOOL LLImageDXT::updateData | ( | ) |  [virtual] | 
Implements LLImageFormatted.
Definition at line 179 of file llimagedxt.cpp.
References LLImageFormatted::calcDiscardLevelBytes(), FALSE, LLImageDXT::dxtfile_header_old_t::format, formatComponents(), LLImageDXT::dxtfile_header_t::pixel_format::fourcc, LLImageDXT::dxtfile_header_t::fourcc, LLImageBase::getData(), LLImageBase::getDataSize(), getFormat(), height, llendl, llerrs, llmin(), MAX_IMAGE_MIP, LLImageDXT::dxtfile_header_t::maxheight, LLImageDXT::dxtfile_header_old_t::maxheight, LLImageDXT::dxtfile_header_old_t::maxlevel, LLImageDXT::dxtfile_header_t::maxwidth, LLImageDXT::dxtfile_header_old_t::maxwidth, mFileFormat, mHeaderSize, LLImageDXT::dxtfile_header_t::num_mips, LLImageDXT::dxtfile_header_t::pixel_fmt, LLImageBase::resetLastError(), S32, LLImageFormatted::setDiscardLevel(), LLImageBase::setLastError(), LLImageBase::setSize(), TRUE, and width.
Referenced by convertToDXR().
| EFileFormat LLImageDXT::mFileFormat  [private] | 
Definition at line 138 of file llimagedxt.h.
Referenced by calcDataSize(), convertToDXR(), decode(), encode(), getFileFormat(), getMipData(), getMipOffset(), isCompressed(), setFormat(), and updateData().
| S32 LLImageDXT::mHeaderSize  [private] | 
Definition at line 139 of file llimagedxt.h.
Referenced by convertToDXR(), encode(), getMipOffset(), setFormat(), and updateData().
 1.4.7
 1.4.7