NAME
vtkWindowLevelLookupTable - map scalar values into colors or colors to scalars; generate color table
SYNOPSIS
#include "/opt/vtk-c++/common/vtkWindowLevelLookupTable.h"
class VTK_EXPORT vtkWindowLevelLookupTable : public vtkLookupTable
vtkWindowLevelLookupTable(int sze=256, int ext=256);
void Build();
static vtkWindowLevelLookupTable *New() {return new vtkWindowLevelLookupTable;};
const char *GetClassName() {return "vtkWindowLevelLookupTable";};
void PrintSelf(ostream& os, vtkIndent indent);
void SetWindow(float);
float GetWindow();
void SetLevel(float);
float GetLevel();
void SetInverseVideo(int);
int GetInverseVideo();
void InverseVideoOn();
void InverseVideoOff();
void SetMinimumColor(unsigned char, unsigned char, unsigned char, unsigned char);
void SetMinimumColor(unsigned char *);
unsigned char *GetMinimumColor();
void GetMinimumColor(unsigned char data[4]);
void SetMaximumColor(unsigned char, unsigned char, unsigned char, unsigned char);
void SetMaximumColor(unsigned char *);
unsigned char *GetMaximumColor();
void GetMaximumColor(unsigned char data[4]);
DESCRIPTION
vtkWindowLevelLookupTable is an object that is used by mapper objects to map scalar values into rgba (red-greenblue-alpha transparency) color specification, or rgba into
scalar values. The color table can be created by direct insertion of color values, or by specifying a window and level. Window / Level is used in medical imaging to specify a lienar greyscale ramp. The Level is the center of the ramp. The Window is the width of the ramp.
CAVEATS
vtkWindowLevelLookupTable is a reference counted object. Therefore, you should always use operator "new" to construct new objects. This procedure will avoid memory problems (see text).
SUMMARY
void SetWindow(float)
Set the Window for the lookuptable. Window is the width of the lookuptable ramp.
void SetLevel(float)
Set the Level for the lookuptable. Level is the center of the ramp of the lookuptable. ramp.
void SetInverseVideo(int)
Set inverse video on or off.
void SetMinimumColor(unsigned char, unsigned char, unsigned char, unsigned char)
void SetMinimumColor(unsigned char *)
Set the Minimum color. All lookup table entries below the start of the ramp will be set to this color.
void SetMaximumColor(unsigned char, unsigned char, unsigned char, unsigned char)
void SetMaximumColor(unsigned char *)
Set the Maximum color. All lookup table entries above the end of the ramp will be set to this color.
vtkWindowLevelLookupTable(int sze, int ext): vtkLookupTable(sze,ext)
Construct with range=(0,1); and hsv ranges set up for rainbow color table (from red to blue).
void Build()
Generate lookup table from window and level. Table is built as a linear ramp, centered at Level and of width Window.