VTK
|
a combination of vtkColorTransferFunction and vtkLookupTable. More...
#include <vtkDiscretizableColorTransferFunction.h>
Public Types | |
typedef vtkColorTransferFunction | Superclass |
![]() | |
typedef vtkScalarsToColors | Superclass |
![]() | |
enum | VectorModes { MAGNITUDE = 0, COMPONENT = 1 } |
typedef vtkObject | Superclass |
![]() | |
typedef vtkObjectBase | Superclass |
Public Member Functions | |
virtual const char * | GetClassName () |
virtual int | IsA (const char *type) |
void | PrintSelf (ostream &os, vtkIndent indent) |
virtual void | Build () |
virtual unsigned char * | MapValue (double v) |
virtual void | GetColor (double v, double rgb[3]) |
double * | GetRGBPoints () |
virtual void | SetAlpha (double alpha) |
virtual vtkIdType | GetNumberOfAvailableColors () |
virtual void | SetDiscretize (int) |
virtual int | GetDiscretize () |
virtual void | DiscretizeOn () |
virtual void | DiscretizeOff () |
virtual void | SetUseLogScale (int useLogScale) |
virtual int | GetUseLogScale () |
void | SetNumberOfValues (vtkIdType number) |
virtual vtkIdType | GetNumberOfValues () |
virtual vtkUnsignedCharArray * | MapScalars (vtkDataArray *scalars, int colorMode, int component) |
virtual void | SetNanColor (double r, double g, double b) |
virtual void | SetNanColor (double rgb[3]) |
virtual int | UsingLogScale () |
![]() | |
void | DeepCopy (vtkColorTransferFunction *f) |
void | ShallowCopy (vtkColorTransferFunction *f) |
int | GetSize () |
void | RemoveAllPoints () |
int | AdjustRange (double range[2]) |
void | BuildFunctionFromTable (double x1, double x2, int size, double *table) |
int | AddRGBPoint (double x, double r, double g, double b) |
int | AddRGBPoint (double x, double r, double g, double b, double midpoint, double sharpness) |
int | AddHSVPoint (double x, double h, double s, double v) |
int | AddHSVPoint (double x, double h, double s, double v, double midpoint, double sharpness) |
int | RemovePoint (double x) |
void | AddRGBSegment (double x1, double r1, double g1, double b1, double x2, double r2, double g2, double b2) |
void | AddHSVSegment (double x1, double h1, double s1, double v1, double x2, double h2, double s2, double v2) |
double * | GetColor (double x) |
double | GetRedValue (double x) |
double | GetGreenValue (double x) |
double | GetBlueValue (double x) |
int | GetNodeValue (int index, double val[6]) |
int | SetNodeValue (int index, double val[6]) |
virtual double * | GetRange () |
virtual void | GetRange (double &, double &) |
virtual void | GetRange (double[2]) |
void | GetTable (double x1, double x2, int n, double *table) |
void | GetTable (double x1, double x2, int n, float *table) |
const unsigned char * | GetTable (double x1, double x2, int n) |
virtual void | SetClamping (int) |
virtual int | GetClamping () |
virtual void | ClampingOn () |
virtual void | ClampingOff () |
virtual void | SetColorSpace (int) |
void | SetColorSpaceToRGB () |
void | SetColorSpaceToHSV () |
void | SetColorSpaceToLab () |
void | SetColorSpaceToDiverging () |
virtual int | GetColorSpace () |
virtual void | SetHSVWrap (int) |
virtual int | GetHSVWrap () |
virtual void | HSVWrapOn () |
virtual void | HSVWrapOff () |
virtual void | SetScale (int) |
void | SetScaleToLinear () |
void | SetScaleToLog10 () |
virtual int | GetScale () |
virtual double * | GetNanColor () |
virtual void | GetNanColor (double &, double &, double &) |
virtual void | GetNanColor (double[3]) |
double * | GetDataPointer () |
void | FillFromDataPointer (int, double *) |
virtual void | MapScalarsThroughTable2 (void *input, unsigned char *output, int inputDataType, int numberOfValues, int inputIncrement, int outputIncrement) |
virtual void | SetAllowDuplicateScalars (int) |
virtual int | GetAllowDuplicateScalars () |
virtual void | AllowDuplicateScalarsOn () |
virtual void | AllowDuplicateScalarsOff () |
![]() | |
virtual int | IsOpaque () |
virtual double | GetOpacity (double vtkNotUsed(v)) |
double | GetLuminance (double x) |
virtual double | GetAlpha () |
virtual void | SetVectorMode (int) |
virtual int | GetVectorMode () |
void | SetVectorModeToMagnitude () |
void | SetVectorModeToComponent () |
virtual void | SetVectorComponent (int) |
virtual int | GetVectorComponent () |
void | MapScalarsThroughTable (vtkDataArray *scalars, unsigned char *output, int outputFormat) |
void | MapScalarsThroughTable (vtkDataArray *scalars, unsigned char *output) |
virtual vtkUnsignedCharArray * | ConvertUnsignedCharToRGBA (vtkUnsignedCharArray *colors, int numComp, int numTuples) |
![]() | |
virtual void | DebugOn () |
virtual void | DebugOff () |
unsigned char | GetDebug () |
void | SetDebug (unsigned char debugFlag) |
virtual void | Modified () |
virtual unsigned long | GetMTime () |
unsigned long | AddObserver (unsigned long event, vtkCommand *, float priority=0.0f) |
unsigned long | AddObserver (const char *event, vtkCommand *, float priority=0.0f) |
vtkCommand * | GetCommand (unsigned long tag) |
void | RemoveObserver (vtkCommand *) |
void | RemoveObservers (unsigned long event, vtkCommand *) |
void | RemoveObservers (const char *event, vtkCommand *) |
int | HasObserver (unsigned long event, vtkCommand *) |
int | HasObserver (const char *event, vtkCommand *) |
void | RemoveObserver (unsigned long tag) |
void | RemoveObservers (unsigned long event) |
void | RemoveObservers (const char *event) |
void | RemoveAllObservers () |
int | HasObserver (unsigned long event) |
int | HasObserver (const char *event) |
template<class U , class T > | |
unsigned long | AddObserver (unsigned long event, U observer, void(T::*callback)(), float priority=0.0f) |
template<class U , class T > | |
unsigned long | AddObserver (unsigned long event, U observer, void(T::*callback)(vtkObject *, unsigned long, void *), float priority=0.0f) |
int | InvokeEvent (unsigned long event, void *callData) |
int | InvokeEvent (const char *event, void *callData) |
int | InvokeEvent (unsigned long event) |
int | InvokeEvent (const char *event) |
![]() | |
const char * | GetClassName () const |
virtual void | Delete () |
virtual void | FastDelete () |
void | Print (ostream &os) |
virtual void | Register (vtkObjectBase *o) |
virtual void | UnRegister (vtkObjectBase *o) |
void | SetReferenceCount (int) |
void | PrintRevisions (ostream &os) |
virtual void | PrintHeader (ostream &os, vtkIndent indent) |
virtual void | PrintTrailer (ostream &os, vtkIndent indent) |
int | GetReferenceCount () |
Static Public Member Functions | |
static vtkDiscretizableColorTransferFunction * | New () |
static int | IsTypeOf (const char *type) |
static vtkDiscretizableColorTransferFunction * | SafeDownCast (vtkObject *o) |
Protected Member Functions | |
vtkDiscretizableColorTransferFunction () | |
~vtkDiscretizableColorTransferFunction () | |
![]() | |
vtkColorTransferFunction () | |
~vtkColorTransferFunction () | |
void | SortAndUpdateRange () |
void | MovePoint (double oldX, double newX) |
virtual void | SetRange (double, double) |
void | SetRange (double rng[2]) |
![]() | |
vtkScalarsToColors () | |
~vtkScalarsToColors () | |
![]() | |
vtkObject () | |
virtual | ~vtkObject () |
virtual void | RegisterInternal (vtkObjectBase *, int check) |
virtual void | UnRegisterInternal (vtkObjectBase *, int check) |
void | InternalGrabFocus (vtkCommand *mouseEvents, vtkCommand *keypressEvents=NULL) |
void | InternalReleaseFocus () |
![]() | |
vtkObjectBase () | |
virtual | ~vtkObjectBase () |
virtual void | CollectRevisions (ostream &os) |
virtual void | ReportReferences (vtkGarbageCollector *) |
vtkObjectBase (const vtkObjectBase &) | |
void | operator= (const vtkObjectBase &) |
Protected Attributes | |
int | Discretize |
int | UseLogScale |
vtkIdType | NumberOfValues |
vtkLookupTable * | LookupTable |
vtkTimeStamp | BuildTime |
![]() | |
vtkColorTransferFunctionInternals * | Internal |
int | Clamping |
int | ColorSpace |
int | HSVWrap |
int | Scale |
double | NanColor [3] |
double * | Function |
double | Range [2] |
unsigned char | UnsignedCharRGBAValue [4] |
int | AllowDuplicateScalars |
vtkTimeStamp | BuildTime |
unsigned char * | Table |
int | TableSize |
![]() | |
double | Alpha |
int | VectorMode |
int | UseMagnitude |
int | VectorComponent |
![]() | |
unsigned char | Debug |
vtkTimeStamp | MTime |
vtkSubjectHelper * | SubjectHelper |
![]() | |
int | ReferenceCount |
vtkWeakPointerBase ** | WeakPointers |
a combination of vtkColorTransferFunction and vtkLookupTable.
This is a cross between a vtkColorTransferFunction and a vtkLookupTable selectively combiniting the functionality of both. NOTE: One must call Build() after making any changes to the points in the ColorTransferFunction to ensure that the discrete and non-discrete version match up.
Definition at line 37 of file vtkDiscretizableColorTransferFunction.h.
Definition at line 41 of file vtkDiscretizableColorTransferFunction.h.
|
protected |
|
protected |
|
static |
Create an object with Debug turned off, modified time initialized to zero, and reference counting on.
Reimplemented from vtkColorTransferFunction.
|
virtual |
Reimplemented from vtkColorTransferFunction.
|
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 vtkTypeMacro found in vtkSetGet.h.
Reimplemented from vtkColorTransferFunction.
|
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 vtkTypeMacro found in vtkSetGet.h.
Reimplemented from vtkColorTransferFunction.
|
static |
Reimplemented from vtkColorTransferFunction.
|
virtual |
Print method for vtkColorTransferFunction
Reimplemented from vtkColorTransferFunction.
|
virtual |
Generate discretized lookup table, if applicable. This method must be called after changes to the ColorTransferFunction otherwise the discretized version will be inconsitent with the non-discretized one.
Reimplemented from vtkScalarsToColors.
|
virtual |
Set if the values are to mapped after discretization. The number of discrete values is set by using SetNumberOfValues(). Not set by default, i.e. color value is determined by interpolating at the scalar value.
|
virtual |
Set if the values are to mapped after discretization. The number of discrete values is set by using SetNumberOfValues(). Not set by default, i.e. color value is determined by interpolating at the scalar value.
|
virtual |
Set if the values are to mapped after discretization. The number of discrete values is set by using SetNumberOfValues(). Not set by default, i.e. color value is determined by interpolating at the scalar value.
|
virtual |
Set if the values are to mapped after discretization. The number of discrete values is set by using SetNumberOfValues(). Not set by default, i.e. color value is determined by interpolating at the scalar value.
|
virtual |
Get/Set if log scale must be used while mapping scalars to colors. The default is 0.
|
virtual |
Get/Set if log scale must be used while mapping scalars to colors. The default is 0.
void vtkDiscretizableColorTransferFunction::SetNumberOfValues | ( | vtkIdType | number | ) |
Set the number of values i.e. colors to be generated in the discrete lookup table. This has no effect if Discretize is off. The default is
|
virtual |
Set the number of values i.e. colors to be generated in the discrete lookup table. This has no effect if Discretize is off. The default is
|
virtual |
Map one value through the lookup table and return a color defined as a RGBA unsigned char tuple (4 bytes).
Reimplemented from vtkColorTransferFunction.
|
virtual |
Map one value through the lookup table and return the color as an RGB array of doubles between 0 and 1.
Reimplemented from vtkColorTransferFunction.
|
virtual |
An internal method maps a data array into a 4-component, unsigned char RGBA array. The color mode determines the behavior of mapping. If VTK_COLOR_MODE_DEFAULT is set, then unsigned char data arrays are treated as colors (and converted to RGBA if necessary); otherwise, the data is mapped through this instance of ScalarsToColors. The offset is used for data arrays with more than one component; it indicates which component to use to do the blending. When the component argument is -1, then the this object uses its own selected technique to change a vector into a scalar to map.
Reimplemented from vtkScalarsToColors.
double* vtkDiscretizableColorTransferFunction::GetRGBPoints | ( | ) |
Returns the (x, r, g, b) values as an array.
|
virtual |
Specify an additional opacity (alpha) value to blend with. Values != 1 modify the resulting color consistent with the requested form of the output. This is typically used by an actor in order to blend its opacity. Overridden to pass the alpha to the internal vtkLookupTable.
Reimplemented from vtkScalarsToColors.
|
virtual |
Set the color to use when a NaN (not a number) is encountered. This is an RGB 3-tuple color of doubles in the range [0,1]. Overridden to pass the NanColor to the internal vtkLookupTable.
Reimplemented from vtkColorTransferFunction.
|
inlinevirtual |
Set the color to use when a NaN (not a number) is encountered. This is an RGB 3-tuple color of doubles in the range [0,1]. Overridden to pass the NanColor to the internal vtkLookupTable.
Reimplemented from vtkColorTransferFunction.
Definition at line 111 of file vtkDiscretizableColorTransferFunction.h.
|
inlinevirtual |
This should return 1 is the subclass is using log scale for mapping scalars to colors.
Reimplemented from vtkScalarsToColors.
Definition at line 120 of file vtkDiscretizableColorTransferFunction.h.
|
virtual |
Get the number of available colors for mapping to.
Reimplemented from vtkColorTransferFunction.
|
protected |
Definition at line 131 of file vtkDiscretizableColorTransferFunction.h.
|
protected |
Definition at line 132 of file vtkDiscretizableColorTransferFunction.h.
|
protected |
Definition at line 134 of file vtkDiscretizableColorTransferFunction.h.
|
protected |
Definition at line 135 of file vtkDiscretizableColorTransferFunction.h.
|
protected |
Definition at line 137 of file vtkDiscretizableColorTransferFunction.h.