#include <mlLUTData.h>

Public Member Functions | |
| virtual | ~LUTDataBase () |
| Destructor. | |
| void | clear (void) |
| Clear. | |
| bool | isInitialized (void) const |
| Return true if LUT initialized. | |
| bool | ownsData (void) const |
| Return true if this LUTData object owns the referenced LUT data buffer. | |
| MLDataType | getDataType (void) const |
| Get data type. | |
| int | getEntrySize (void) const |
| Get size of a single LUT entry. | |
| LUTVisualType | getVisualType (void) const |
| Get visual type. | |
| int | getNumChannels (void) const |
| Get number of channels. | |
| LUTDimensionality | getDimensionality (void) const |
| Get number of dimensions (1, 2, or 3). | |
| int | getMinIndex (void) const |
| Get minimum index value. | |
| int | getMaxIndex (void) const |
| Get maximum index value. | |
| int | getWidth (void) const |
| Get index range width. | |
| int | getMinRow (void) const |
| Get minimum row value. | |
| int | getMaxRow (void) const |
| Get maximum row value. | |
| int | getHeight (void) const |
| Get number of rows. | |
| int | getMinLayer (void) const |
| Get minimum layer value. | |
| int | getMaxLayer (void) const |
| Get maximum layer value. | |
| int | getDepth (void) const |
| Get number of layers. | |
| int | getLength (void) const |
| Get total number of entries. | |
| int | getStride (int dim) const |
| Get entry stride for index (dim = 1), row (2) and layer (3) dimension, relative to entry size, i.e. | |
| int | getDataSize (void) const |
| Get size of LUT data area (in bytes). | |
| bool | isInRange (int index, int row=0, int layer=0) const |
| Return true if specified index, row and layer position is in LUT range. | |
| unsigned int | getId (void) const |
| Get LUT ID. | |
| void | setId (unsigned int id) |
| Set LUT ID. | |
Protected Member Functions | |
| LUTDataBase (MLDataType dataType) | |
| Constructor, create empty, unallocated table. | |
| MLErrorCode | init (LUTVisualType visualType, int minIndex, int maxIndex, int minRow, int maxRow, int minLayer, int maxLayer) |
| Initialize LUT data for specified visual type and index/row/layer ranges. | |
| MLErrorCode | initShared1D (LUTVisualType visualType, int minIndex, int maxIndex, int row, int layer, LUTDataBase *srcLutData, int srcIndex, int srcRow, int srcLayer) |
| Initialize 1D-LUT data for specified visual type, index range and row/layer. | |
| MLErrorCode | initShared2D (LUTVisualType visualType, int minRow, int maxRow, int layer, LUTDataBase *srcLutData, int srcRow, int srcLayer) |
| Initialize 2D-LUT data for specified visual type, row range and layer. | |
| void | reset (void) |
| Reset properties. | |
| void | clearData (void) |
| Clear data buffer. | |
| bool | initData (void) |
| Initialize data buffer, return true if successful. | |
Protected Attributes | |
| MLDataType | _dataType |
| Data type identifier constant. | |
| int | _entrySize |
| Size of single data entry. | |
| int | _dataLength |
| Number of entries. | |
| void * | _data |
| LUT data pointer. | |
| bool | _ownsData |
| This flag is true if LUT data buffer is owned by this LUTData object. | |
| LUTVisualType | _visualType |
| Visual type. | |
| int | _numChannels |
| Number of channels. | |
| LUTDimensionality | _dimensionality |
| Dimensionality (1, 2 or 3). | |
| int | _minIndex |
| Index range (1st dimension). | |
| int | _maxIndex |
| int | _minRow |
| Row range (2nd dimension). | |
| int | _maxRow |
| int | _minLayer |
| Layer range (3rd dimension). | |
| int | _maxLayer |
| int | _strides [3] |
| Data strides (entry address differences) for index (1st), row (2nd) and layer (3rd) dimension (relative to entry size). | |
| int | _entryOffset |
| Entry offset for addressing via getEntriesAt() in derived LUTData class. | |
| unsigned int | _id |
| LUT ID. | |
Store instances of a LUT rendered for a given visual type, reference value and index, row and layer range. This class has a protected constructor, i.e. can only be instantiated by derived classes. The type information stored in this class can be used to typecast a pointer to the appropriate derived LUTData class. The ID stored with each LUTDataBase object can be used to identify the source the LUT was rendered from, e.g. the LUTFunction.
Definition at line 42 of file mlLUTData.h.
| ml::LUTDataBase::LUTDataBase | ( | MLDataType | dataType | ) | [protected] |
Constructor, create empty, unallocated table.
| virtual ml::LUTDataBase::~LUTDataBase | ( | ) | [inline, virtual] |
| void ml::LUTDataBase::clear | ( | void | ) |
Clear.
| void ml::LUTDataBase::clearData | ( | void | ) | [protected] |
Clear data buffer.
| int ml::LUTDataBase::getDataSize | ( | void | ) | const [inline] |
| MLDataType ml::LUTDataBase::getDataType | ( | void | ) | const [inline] |
| int ml::LUTDataBase::getDepth | ( | void | ) | const [inline] |
| LUTDimensionality ml::LUTDataBase::getDimensionality | ( | void | ) | const [inline] |
| int ml::LUTDataBase::getEntrySize | ( | void | ) | const [inline] |
| int ml::LUTDataBase::getHeight | ( | void | ) | const [inline] |
| unsigned int ml::LUTDataBase::getId | ( | void | ) | const [inline] |
| int ml::LUTDataBase::getLength | ( | void | ) | const [inline] |
| int ml::LUTDataBase::getMaxIndex | ( | void | ) | const [inline] |
| int ml::LUTDataBase::getMaxLayer | ( | void | ) | const [inline] |
| int ml::LUTDataBase::getMaxRow | ( | void | ) | const [inline] |
| int ml::LUTDataBase::getMinIndex | ( | void | ) | const [inline] |
Get minimum index value.
Definition at line 98 of file mlLUTData.h.
Referenced by ml::LUTIterator< T >::init().
| int ml::LUTDataBase::getMinLayer | ( | void | ) | const [inline] |
| int ml::LUTDataBase::getMinRow | ( | void | ) | const [inline] |
| int ml::LUTDataBase::getNumChannels | ( | void | ) | const [inline] |
| int ml::LUTDataBase::getStride | ( | int | dim | ) | const |
Get entry stride for index (dim = 1), row (2) and layer (3) dimension, relative to entry size, i.e.
each entry counts as 1. Return 0 if dim is invalid for the present LUT data.
Referenced by ml::LUTIterator< T >::init().
| LUTVisualType ml::LUTDataBase::getVisualType | ( | void | ) | const [inline] |
Get visual type.
Definition at line 89 of file mlLUTData.h.
Referenced by ml::LUTFCompose::getRenderType(), ml::LUTFBlend::getRenderType(), and ml::LUTIterator< T >::init().
| int ml::LUTDataBase::getWidth | ( | void | ) | const [inline] |
| MLErrorCode ml::LUTDataBase::init | ( | LUTVisualType | visualType, | |
| int | minIndex, | |||
| int | maxIndex, | |||
| int | minRow, | |||
| int | maxRow, | |||
| int | minLayer, | |||
| int | maxLayer | |||
| ) | [protected] |
Initialize LUT data for specified visual type and index/row/layer ranges.
| bool ml::LUTDataBase::initData | ( | void | ) | [protected] |
Initialize data buffer, return true if successful.
| MLErrorCode ml::LUTDataBase::initShared1D | ( | LUTVisualType | visualType, | |
| int | minIndex, | |||
| int | maxIndex, | |||
| int | row, | |||
| int | layer, | |||
| LUTDataBase * | srcLutData, | |||
| int | srcIndex, | |||
| int | srcRow, | |||
| int | srcLayer | |||
| ) | [protected] |
Initialize 1D-LUT data for specified visual type, index range and row/layer.
The LUT data buffer is shared with the data buffer of srcLutData, starting at specified srcIndex, srcRow and srcLayer. An error is returned if the requested visual type and index range is incompatible with the source LUTData.
| MLErrorCode ml::LUTDataBase::initShared2D | ( | LUTVisualType | visualType, | |
| int | minRow, | |||
| int | maxRow, | |||
| int | layer, | |||
| LUTDataBase * | srcLutData, | |||
| int | srcRow, | |||
| int | srcLayer | |||
| ) | [protected] |
Initialize 2D-LUT data for specified visual type, row range and layer.
The LUT data buffer is shared with the data buffer of srcLutData, starting at specified srcRow and srcLayer. An error is returned if the requested visual type and row range is incompatible with the source LUTData.
| bool ml::LUTDataBase::isInitialized | ( | void | ) | const [inline] |
| bool ml::LUTDataBase::isInRange | ( | int | index, | |
| int | row = 0, |
|||
| int | layer = 0 | |||
| ) | const |
Return true if specified index, row and layer position is in LUT range.
| bool ml::LUTDataBase::ownsData | ( | void | ) | const [inline] |
Return true if this LUTData object owns the referenced LUT data buffer.
Definition at line 80 of file mlLUTData.h.
| void ml::LUTDataBase::reset | ( | void | ) | [protected] |
Reset properties.
| void ml::LUTDataBase::setId | ( | unsigned int | id | ) | [inline] |
void* ml::LUTDataBase::_data [protected] |
int ml::LUTDataBase::_dataLength [protected] |
MLDataType ml::LUTDataBase::_dataType [protected] |
LUTDimensionality ml::LUTDataBase::_dimensionality [protected] |
int ml::LUTDataBase::_entryOffset [protected] |
Entry offset for addressing via getEntriesAt() in derived LUTData class.
Definition at line 198 of file mlLUTData.h.
int ml::LUTDataBase::_entrySize [protected] |
unsigned int ml::LUTDataBase::_id [protected] |
int ml::LUTDataBase::_maxIndex [protected] |
int ml::LUTDataBase::_maxLayer [protected] |
int ml::LUTDataBase::_maxRow [protected] |
int ml::LUTDataBase::_minIndex [protected] |
Index range (1st dimension).
Definition at line 185 of file mlLUTData.h.
Referenced by ml::LUTData< T >::clone().
int ml::LUTDataBase::_minLayer [protected] |
Layer range (3rd dimension).
Definition at line 191 of file mlLUTData.h.
Referenced by ml::LUTData< T >::clone().
int ml::LUTDataBase::_minRow [protected] |
Row range (2nd dimension).
Definition at line 188 of file mlLUTData.h.
Referenced by ml::LUTData< T >::clone().
int ml::LUTDataBase::_numChannels [protected] |
bool ml::LUTDataBase::_ownsData [protected] |
This flag is true if LUT data buffer is owned by this LUTData object.
Definition at line 172 of file mlLUTData.h.
int ml::LUTDataBase::_strides[3] [protected] |
Data strides (entry address differences) for index (1st), row (2nd) and layer (3rd) dimension (relative to entry size).
Definition at line 195 of file mlLUTData.h.
LUTVisualType ml::LUTDataBase::_visualType [protected] |
1.5.8