MeVisLab Toolbox Reference
Loading...
Searching...
No Matches
mlLUTFloatRGBA.h
Go to the documentation of this file.
1/*************************************************************************************
2**
3** Copyright 2007, MeVis Medical Solutions AG
4**
5** The user may use this file in accordance with the license agreement provided with
6** the Software or, alternatively, in accordance with the terms contained in a
7** written agreement between the user and MeVis Medical Solutions AG.
8**
9** For further information use the contact form at https://www.mevislab.de/contact
10**
11**************************************************************************************/
12
13#ifndef ML_LUTFLOAT_RGBA_H
14#define ML_LUTFLOAT_RGBA_H
15
16
23
24#include "mlLUTSystem.h"
25#include "mlLUTBasic.h"
26#include "mlLUTFunction.h"
27#include "mlLUTData.h"
28
29
31
39{
40
41public:
42 struct LUTIndex
43 {
44 explicit LUTIndex(int index)
45 : value(index)
46 {}
47 int value;
48 };
49
56 bool continuousIndexRange = true);
57
64
67
75 float* getColorAt(double value);
76
79 bool isValid();
80
81private:
83 double _minIndex;
85 double _maxIndex;
86
88 LUTFunction* _lutFunction;
90 LUTData<float>* _lutData;
92 float* _rgbaColorLut;
93
95 double _indexScale;
97 double _indexShift;
98
101 bool _isValid;
102};
103
104
106
107
108#endif // __mlLUTFloatRGBA_H
A LUTData object stores an instance of a LUT, rendered for a specified visual type,...
Definition mlLUTData.h:308
Implements a float RGBA color table.
LUTFloatRGBA(LUTFunction *lutFunction, double minIndex, double maxIndex, bool continuousIndexRange=true)
Constructor takes a LUT function, the min and max indices as the range for the color table.
~LUTFloatRGBA()
Default destructor.
LUTFloatRGBA(LUTFunction *lutFunction, double minIndex, double maxIndex, LUTIndex lutIndex, bool continuousIndexRange=true)
Constructor takes a LUT function, the min and max indices as the range for the color table.
float * getColorAt(double value)
Returns the color of a given value as an index into the color table.
bool isValid()
Returns whether the construction of the internal color table was successful.
Common base class for lookup tables.
#define MLLUT_EXPORT
System specific macro definitions.
Definition mlLUTSystem.h:25
Target mlrange_cast(Source arg)
Generic version of checked ML casts.