From 0ea5fc66924303d1bf73ba283a383e2aadee02f2 Mon Sep 17 00:00:00 2001 From: neodarz Date: Sat, 11 Aug 2018 20:21:34 +0200 Subject: Initial commit --- .../doxygen/nel/classNL3D_1_1CHLSColorTexture.html | 776 +++++++++++++++++++++ 1 file changed, 776 insertions(+) create mode 100644 docs/doxygen/nel/classNL3D_1_1CHLSColorTexture.html (limited to 'docs/doxygen/nel/classNL3D_1_1CHLSColorTexture.html') diff --git a/docs/doxygen/nel/classNL3D_1_1CHLSColorTexture.html b/docs/doxygen/nel/classNL3D_1_1CHLSColorTexture.html new file mode 100644 index 00000000..300d7777 --- /dev/null +++ b/docs/doxygen/nel/classNL3D_1_1CHLSColorTexture.html @@ -0,0 +1,776 @@ + + + + nevrax.org : docs + + + + + + + + + + + + + + +
# Home   # nevrax.com   
+ + + + +
Nevrax
+ + + + + + + + + + +
+ + +
+ Nevrax.org
+ + + + + + + +
#News
#Mailing-list
#Documentation
#CVS
#Bugs
#License
+
+ + +
+ + +
+Docs + +
+  + + + + + +
Documentation 
+ +
+Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages   Search  
+

NL3D::CHLSColorTexture Class Reference

A colorisable texture. +More... +

+#include <hls_color_texture.h> +

+List of all members. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

Public Methods

 CHLSColorTexture ()
void reset ()
 reset the build. More...

void setBitmap (const NLMISC::CBitmap &bmp)
 setup the un-colored bitmap for the texture. More...

void addMask (const NLMISC::CBitmap &bmp, uint threshold=15)
 add a mask to the texture. More...

uint getNumMasks () const
 get num of masks. More...

void buildColorVersion (const CHLSColorDelta *colDeltaList, NLMISC::CBitmap &out)
 build a texture with a HLS Color Delta. More...

void serial (NLMISC::IStream &f)

Static Private Methods

void uncompressBlockRGB (const uint8 *srcDXTC, CRGBA *dstRGBA)
 uncompress DXTC5 RGB only block, into a RGBA raw array. Alpha is setup with undefined values. More...

void compressBlockRGB (CRGBA *srcRGBA, uint8 *dstDXTC)
 compress DXTC5 RGB only block, from a RGBA raw array. dstDXTC Alpha part is not modified. srcRGBA->A are setup to 0!! More...

void computeMinMax (sint *diffBlock, CVectorInt &v, sint mean[3], sint rgb0[3], sint rgb1[3])
 used by compressBlockRGB(). More...

void colorizeDXTCBlockRGB (const uint8 *srcPtr, uint8 *dstPtr, uint8 dHue, uint dLum, uint dSat)
 apply colDelta to the block. Alpha part is not modified. MMX with no EMMS called here !!! More...


Private Attributes

uint32 _Width
uint32 _Height
uint32 _NumMipMap
uint32 _BlockToCompressIndex
std::vector< uint8_Texture
std::vector< CMask_Masks
+


Detailed Description

+A colorisable texture. +

+

+Author:
+Lionel Berenguier , Nevrax France
+Date:
+2002
+

+ +

+Definition at line 70 of file hls_color_texture.h.


Constructor & Destructor Documentation

+

+ + + + +
+ + + + + + + + + +
NL3D::CHLSColorTexture::CHLSColorTexture  
+
+ + + + + +
+   + + +

+ +

+Definition at line 76 of file hls_color_texture.cpp. +

+References reset.

+


Member Function Documentation

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + +
void NL3D::CHLSColorTexture::addMask const NLMISC::CBitmap  bmp,
uint   threshold = 15
+
+ + + + + +
+   + + +

+add a mask to the texture. +

+R is taken as the mask value. must be same size as in setBitmap()

+Parameters:
+ + +
threshold  +used to know if a pixel mask value is or not an intermediate (ie not 0 or 255)
+
+

+Definition at line 152 of file hls_color_texture.cpp. +

+References _BlockToCompressIndex, _Height, _Masks, _NumMipMap, _Texture, _Width, BLOCK_ALPHA_SIZE, NLMISC::CBitmap::convertToType, id, MASK_BLOCK_EMPTY, MASK_BLOCK_FULL, MASK_BLOCK_MIXT, min, nlassert, src, w, x, and y.

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + +
void NL3D::CHLSColorTexture::buildColorVersion const CHLSColorDelta  colDeltaList,
NLMISC::CBitmap  out
+
+ + + + + +
+   + + +

+build a texture with a HLS Color Delta. +

+

+Parameters:
+ + + +
colDelta  +array of delta to apply to the bitmap (must be of numMasks entries)
out  +a colorised bitmap with DXTC5/mipMaps generated
+
+

+Definition at line 337 of file hls_color_texture.cpp. +

+References _BlockToCompressIndex, _Height, _Masks, _NumMipMap, _Texture, _Width, BLOCK_DXTC_SIZE, BLOCK_NUM_PIXEL, colorizeDXTCBlockRGB, compressBlockRGB, NL3D::getBitPack, NLMISC::CBitmap::getPixels, min, nlassert, NLMISC::CBitmap::reset, NLMISC::CBitmap::resize, NLMISC::CBitmap::resizeMipMap, NLMISC::CBitmap::setMipMapCount, uncompressBlockRGB, and w.

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
void NL3D::CHLSColorTexture::colorizeDXTCBlockRGB const uint8  srcPtr,
uint8  dstPtr,
uint8   dHue,
uint   dLum,
uint   dSat
[static, private]
+
+ + + + + +
+   + + +

+apply colDelta to the block. Alpha part is not modified. MMX with no EMMS called here !!! +

+ +

+Definition at line 545 of file hls_color_texture.cpp. +

+Referenced by buildColorVersion.

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + +
void NL3D::CHLSColorTexture::compressBlockRGB CRGBA *   srcRGBA,
uint8  dstDXTC
[static, private]
+
+ + + + + +
+   + + +

+compress DXTC5 RGB only block, from a RGBA raw array. dstDXTC Alpha part is not modified. srcRGBA->A are setup to 0!! +

+ +

+Definition at line 628 of file hls_color_texture.cpp. +

+References computeMinMax, id, NL3D::OptFastFloor, NLMISC::sqr, src, and v. +

+Referenced by buildColorVersion.

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
void NL3D::CHLSColorTexture::computeMinMax sint  diffBlock,
CVectorInt  v,
sint   mean[3],
sint   rgb0[3],
sint   rgb1[3]
[static, private]
+
+ + + + + +
+   + + +

+used by compressBlockRGB(). +

+ +

+Definition at line 586 of file hls_color_texture.cpp. +

+References v. +

+Referenced by compressBlockRGB.

+

+ + + + +
+ + + + + + + + + +
uint NL3D::CHLSColorTexture::getNumMasks   const [inline]
+
+ + + + + +
+   + + +

+get num of masks. +

+ +

+Definition at line 90 of file hls_color_texture.h. +

+References _Masks.

+

+ + + + +
+ + + + + + + + + +
void NL3D::CHLSColorTexture::reset  
+
+ + + + + +
+   + + +

+reset the build. +

+ +

+Definition at line 82 of file hls_color_texture.cpp. +

+References _Height, _Masks, _NumMipMap, _Texture, _Width, and NLMISC::contReset. +

+Referenced by CHLSColorTexture, and setBitmap.

+

+ + + + +
+ + + + + + + + + + +
void NL3D::CHLSColorTexture::serial NLMISC::IStream  f
+
+ + + + + +
+   + + +

+ +

+Definition at line 313 of file hls_color_texture.cpp. +

+References _BlockToCompressIndex, _Height, _Masks, _NumMipMap, _Texture, _Width, NLMISC::IStream::serial, NLMISC::IStream::serialCont, and NLMISC::IStream::serialVersion.

+

+ + + + +
+ + + + + + + + + + +
void NL3D::CHLSColorTexture::setBitmap const NLMISC::CBitmap  bmp
+
+ + + + + +
+   + + +

+setup the un-colored bitmap for the texture. +

+

+Parameters:
+ + +
bmp  +a bitmap which must be a DXTC5 with all mipmaps.
+
+

+Definition at line 92 of file hls_color_texture.cpp. +

+References _BlockToCompressIndex, _Height, _NumMipMap, _Texture, _Width, NLMISC::CBitmap::getHeight, NLMISC::CBitmap::getMipMapCount, NLMISC::CBitmap::getPixelFormat, NLMISC::CBitmap::getPixels, NLMISC::CBitmap::getWidth, height, nlassert, reset, and width.

+

+ + + + +
+ + + + + + + + + + + + + + + + + + + +
void NL3D::CHLSColorTexture::uncompressBlockRGB const uint8  srcDXTC,
CRGBA *   dstRGBA
[static, private]
+
+ + + + + +
+   + + +

+uncompress DXTC5 RGB only block, into a RGBA raw array. Alpha is setup with undefined values. +

+ +

+Definition at line 557 of file hls_color_texture.cpp. +

+Referenced by buildColorVersion.

+


Member Data Documentation

+

+ + + + +
+ + +
uint32 NL3D::CHLSColorTexture::_BlockToCompressIndex [private] +
+
+ + + + + +
+   + + +

+ +

+Definition at line 126 of file hls_color_texture.h. +

+Referenced by addMask, buildColorVersion, serial, and setBitmap.

+

+ + + + +
+ + +
uint32 NL3D::CHLSColorTexture::_Height [private] +
+
+ + + + + +
+   + + +

+ +

+Definition at line 125 of file hls_color_texture.h. +

+Referenced by addMask, buildColorVersion, reset, serial, and setBitmap.

+

+ + + + +
+ + +
std::vector<CMask> NL3D::CHLSColorTexture::_Masks [private] +
+
+ + + + + +
+   + + +

+ +

+Definition at line 130 of file hls_color_texture.h. +

+Referenced by addMask, buildColorVersion, getNumMasks, reset, and serial.

+

+ + + + +
+ + +
uint32 NL3D::CHLSColorTexture::_NumMipMap [private] +
+
+ + + + + +
+   + + +

+ +

+Definition at line 125 of file hls_color_texture.h. +

+Referenced by addMask, buildColorVersion, reset, serial, and setBitmap.

+

+ + + + +
+ + +
std::vector<uint8> NL3D::CHLSColorTexture::_Texture [private] +
+
+ + + + + +
+   + + +

+ +

+Definition at line 128 of file hls_color_texture.h. +

+Referenced by addMask, buildColorVersion, reset, serial, and setBitmap.

+

+ + + + +
+ + +
uint32 NL3D::CHLSColorTexture::_Width [private] +
+
+ + + + + +
+   + + +

+ +

+Definition at line 125 of file hls_color_texture.h. +

+Referenced by addMask, buildColorVersion, reset, serial, and setBitmap.

+


The documentation for this class was generated from the following files: + + + +
                                                                                                                                                                    +
+ + -- cgit v1.2.1