Main Page Class Hierarchy Alphabetical List Compound List File List Compound Members File Members Related Pages

# vtkImageMapToColors Class Reference

`#include <vtkImageMapToColors.h>`

Inheritance diagram for vtkImageMapToColors:

[legend]
Collaboration diagram for vtkImageMapToColors:

[legend]
List of all members.

## Detailed Description

map the input image through a lookup table

Date:
  2002/12/11 14:26:22

Revision:
  1.19

The vtkImageMapToColors filter will take an input image of any valid scalar type, and map the first component of the image through a lookup table. The result is an image of type VTK_UNSIGNED_CHAR. If the lookup table is not set, or is set to NULL, then the input data will be passed through if it is already of type UNSIGNED_CHAR.

See also:
  vtkLookupTable vtkScalarsToColors

Created by:
  - Gobbi, David

CVS contributions (if > 5%):
  - Gobbi, David (88%)

CVS logs (CVSweb):
  - .`h` (`/Imaging/vtkImageMapToColors.h)`
  - .`cxx` (`/Imaging/vtkImageMapToColors.cxx)`

Examples:
  vtkImageMapToColors (Examples)

Tests:
  vtkImageMapToColors (Tests)

Definition at line 56 of file vtkImageMapToColors.h.

## Public Types

typedef vtkImageToImageFilter | Superclass

## Public Methods

virtual const char * | GetClassName ()
virtual int | IsA (const char *type)
void | PrintSelf (ostream &os, vtkIndent indent)
unsigned long | GetMTime ()
virtual void | SetLookupTable (vtkScalarsToColors *)
virtual vtkScalarsToColors * | GetLookupTable ()
virtual void | SetOutputFormat (int)
virtual int | GetOutputFormat ()
void | SetOutputFormatToRGBA ()
void | SetOutputFormatToRGB ()
void | SetOutputFormatToLuminanceAlpha ()
void | SetOutputFormatToLuminance ()
virtual void | SetActiveComponent (int)
virtual int | GetActiveComponent ()
virtual void | SetPassAlphaToOutput (int)
virtual void | PassAlphaToOutputOn ()
virtual void | PassAlphaToOutputOff ()
virtual int | GetPassAlphaToOutput ()

## Static Public Methods

vtkImageMapToColors * | New ()
int | IsTypeOf (const char *type)
vtkImageMapToColors * | SafeDownCast (vtkObject *o)

## Protected Methods

| vtkImageMapToColors ()
| ~vtkImageMapToColors ()
void | ExecuteInformation (vtkImageData *inData, vtkImageData *outData)
void | ExecuteInformation ()
void | ThreadedExecute (vtkImageData *inData, vtkImageData *outData, int extent[6], int id)
void | ExecuteData (vtkDataObject *output)

## Protected Attributes

vtkScalarsToColors * | LookupTable
int | OutputFormat
int | ActiveComponent
int | PassAlphaToOutput
int | DataWasPassed

## Member Typedef Documentation

typedef vtkImageToImageFilter vtkImageMapToColors::Superclass

| Reimplemented from vtkImageToImageFilter. Reimplemented in vtkImageMapToRGBA, and vtkImageMapToWindowLevelColors. Definition at line 60 of file vtkImageMapToColors.h.

## Constructor & Destructor Documentation

vtkImageMapToColors::vtkImageMapToColors | ( |  | ) | `[protected]`

vtkImageMapToColors::~vtkImageMapToColors | ( |  | ) | `[protected]`

## Member Function Documentation

vtkImageMapToColors* vtkImageMapToColors::New | ( |  | ) | `[static]`

| Create an object with Debug turned off, modified time initialized to zero, and reference counting on. Reimplemented from vtkObject. Reimplemented in vtkImageMapToRGBA, and vtkImageMapToWindowLevelColors.

virtual const char* vtkImageMapToColors::GetClassName | ( |  | ) | `[virtual]`

| Reimplemented from vtkImageToImageFilter. Reimplemented in vtkImageMapToRGBA, and vtkImageMapToWindowLevelColors.

int vtkImageMapToColors::IsTypeOf | ( | const char * | type | ) | `[static]`

| Return 1 if this class type is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeRevisionMacro found in vtkSetGet.h. Reimplemented from vtkImageToImageFilter. Reimplemented in vtkImageMapToRGBA, and vtkImageMapToWindowLevelColors.

virtual int vtkImageMapToColors::IsA | ( | const char * | type | ) | `[virtual]`

| Return 1 if this class is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeRevisionMacro found in vtkSetGet.h. Reimplemented from vtkImageToImageFilter. Reimplemented in vtkImageMapToRGBA, and vtkImageMapToWindowLevelColors.

vtkImageMapToColors* vtkImageMapToColors::SafeDownCast | ( | vtkObject * | o | ) | `[static]`

| Reimplemented from vtkImageToImageFilter. Reimplemented in vtkImageMapToRGBA, and vtkImageMapToWindowLevelColors.

void vtkImageMapToColors::PrintSelf | ( | ostream & | os,
|  | vtkIndent | indent
| ) | `[virtual]`

| Methods invoked by print to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes. Reimplemented from vtkImageToImageFilter. Reimplemented in vtkImageMapToWindowLevelColors.

virtual void vtkImageMapToColors::SetLookupTable | ( | vtkScalarsToColors * |  | ) | `[virtual]`

| Set the lookup table.

virtual vtkScalarsToColors* vtkImageMapToColors::GetLookupTable | ( |  | ) | `[virtual]`

| Set the lookup table.

virtual void vtkImageMapToColors::SetOutputFormat | ( | int |  | ) | `[virtual]`

| Set the output format, the default is RGBA.

virtual int vtkImageMapToColors::GetOutputFormat | ( |  | ) | `[virtual]`

| Set the output format, the default is RGBA.

void vtkImageMapToColors::SetOutputFormatToRGBA | ( |  | ) | `[inline]`

| Set the output format, the default is RGBA. Definition at line 73 of file vtkImageMapToColors.h. References VTK_RGBA.

void vtkImageMapToColors::SetOutputFormatToRGB | ( |  | ) | `[inline]`

| Set the output format, the default is RGBA. Definition at line 74 of file vtkImageMapToColors.h. References VTK_RGB.

void vtkImageMapToColors::SetOutputFormatToLuminanceAlpha | ( |  | ) | `[inline]`

| Set the output format, the default is RGBA. Definition at line 75 of file vtkImageMapToColors.h. References VTK_LUMINANCE_ALPHA.

void vtkImageMapToColors::SetOutputFormatToLuminance | ( |  | ) | `[inline]`

| Set the output format, the default is RGBA. Definition at line 76 of file vtkImageMapToColors.h. References VTK_LUMINANCE.

virtual void vtkImageMapToColors::SetActiveComponent | ( | int |  | ) | `[virtual]`

| Set the component to map for multi-component images (default: 0)

virtual int vtkImageMapToColors::GetActiveComponent | ( |  | ) | `[virtual]`

| Set the component to map for multi-component images (default: 0)

virtual void vtkImageMapToColors::SetPassAlphaToOutput | ( | int |  | ) | `[virtual]`

| Use the alpha component of the input when computing the alpha component of the output (useful when converting monochrome+alpha data to RGBA)

virtual void vtkImageMapToColors::PassAlphaToOutputOn | ( |  | ) | `[virtual]`

| Use the alpha component of the input when computing the alpha component of the output (useful when converting monochrome+alpha data to RGBA)

virtual void vtkImageMapToColors::PassAlphaToOutputOff | ( |  | ) | `[virtual]`

| Use the alpha component of the input when computing the alpha component of the output (useful when converting monochrome+alpha data to RGBA)

virtual int vtkImageMapToColors::GetPassAlphaToOutput | ( |  | ) | `[virtual]`

| Use the alpha component of the input when computing the alpha component of the output (useful when converting monochrome+alpha data to RGBA)

unsigned long vtkImageMapToColors::GetMTime | ( |  | ) | `[virtual]`

| We need to check the modified time of the lookup table too. Reimplemented from vtkObject.

void vtkImageMapToColors::ExecuteInformation | ( | vtkImageData * | inData,
|  | vtkImageData * | outData
| ) | `[protected, virtual]`

| Reimplemented from vtkImageToImageFilter. Reimplemented in vtkImageMapToWindowLevelColors.

void vtkImageMapToColors::ExecuteInformation | ( |  | ) | `[inline, protected, virtual]`

| Reimplemented from vtkImageToImageFilter. Reimplemented in vtkImageMapToWindowLevelColors. Definition at line 102 of file vtkImageMapToColors.h. References vtkImageToImageFilter::ExecuteInformation(). Referenced by vtkImageMapToWindowLevelColors::ExecuteInformation().

void vtkImageMapToColors::ThreadedExecute | ( | vtkImageData * | inData,
|  | vtkImageData * | outData,
|  | int | extent[6],
|  | int | id
| ) | `[protected, virtual]`

| If the subclass does not define an Execute method, then the task will be broken up, multiple threads will be spawned, and each thread will call this method. It is public so that the thread functions can call this method. Reimplemented from vtkImageToImageFilter. Reimplemented in vtkImageMapToWindowLevelColors.

void vtkImageMapToColors::ExecuteData | ( | vtkDataObject * | output | ) | `[protected]`

| Reimplemented from vtkImageToImageFilter. Reimplemented in vtkImageMapToWindowLevelColors.

## Member Data Documentation

vtkScalarsToColors* vtkImageMapToColors::LookupTable`[protected]`

| Definition at line 109 of file vtkImageMapToColors.h.

int vtkImageMapToColors::OutputFormat`[protected]`

| Definition at line 110 of file vtkImageMapToColors.h.

int vtkImageMapToColors::ActiveComponent`[protected]`

| Definition at line 112 of file vtkImageMapToColors.h.

int vtkImageMapToColors::PassAlphaToOutput`[protected]`

| Definition at line 113 of file vtkImageMapToColors.h.

int vtkImageMapToColors::DataWasPassed`[protected]`

| Definition at line 115 of file vtkImageMapToColors.h.

The documentation for this class was generated from the following file:

- Imaging/vtkImageMapToColors.h