42 #ifndef vtkDiscretizableColorTransferFunction_h
43 #define vtkDiscretizableColorTransferFunction_h
45 #include "vtkRenderingCoreModule.h"
72 void SetIndexedColor(
unsigned int index, const
double rgb[3])
73 { this->SetIndexedColor(index, rgb[0], rgb[1], rgb[2]); }
74 void SetIndexedColor(
unsigned int index,
double r,
double g,
double b);
96 void SetNumberOfIndexedColors(
unsigned int count);
97 unsigned int GetNumberOfIndexedColors();
106 void Build() VTK_OVERRIDE;
116 vtkGetMacro(Discretize,
int);
125 virtual
void SetUseLogScale(
int useLogScale);
126 vtkGetMacro(UseLogScale,
int);
136 vtkGetMacro(NumberOfValues, vtkIdType);
143 unsigned char *MapValue(
double v) VTK_OVERRIDE;
149 void GetColor(
double v,
double rgb[3]) VTK_OVERRIDE;
154 double GetOpacity(
double v) VTK_OVERRIDE;
184 VTK_LEGACY(
double* GetRGBPoints());
193 void SetAlpha(
double alpha) VTK_OVERRIDE;
201 void SetNanColor(
double r,
double g,
double b) VTK_OVERRIDE;
202 void SetNanColor(
double rgb[3]) VTK_OVERRIDE {
212 {
return this->UseLogScale; }
232 vtkGetMacro(EnableOpacityMapping,
bool)
243 ~vtkDiscretizableColorTransferFunction() VTK_OVERRIDE;
267 bool EnableOpacityMapping;
270 void MapDataArrayToOpacity(
274 vtkDiscretizableColorTransferFunction(const vtkDiscretizableColorTransferFunction&) VTK_DELETE_FUNCTION;
275 void operator=(const vtkDiscretizableColorTransferFunction&) VTK_DELETE_FUNCTION;
277 template<typename T, typename VectorGetter>
278 void MapVectorToOpacity (
279 VectorGetter getter, T* scalars,
int component,
280 int numberOfComponents,
vtkIdType numberOfTuples,
unsigned char* colors);
282 template<template<class> class VectorGetter>
283 void AllTypesMapVectorToOpacity (
285 void* scalarsPtr,
int component,
286 int numberOfComponents,
vtkIdType numberOfTuples,
unsigned char* colors);
289 vtkInternals* Internals;
Defines a 1D piecewise function.
vtkTypeUInt32 vtkMTimeType
void PrintSelf(ostream &os, vtkIndent indent) override
Print method for vtkColorTransferFunction.
Abstract superclass for all arrays.
void GetIndexedColor(vtkIdType idx, double rgba[4]) override
Return a color given an integer index.
record modification and/or execution time
static vtkColorTransferFunction * New()
map scalar values into colors via a lookup table
Hold a reference to a vtkObjectBase instance.
virtual void SetNanColor(double, double, double)
Set the RGB color to use when a NaN (not a number) is encountered.
virtual int IsOpaque()
Return true if all of the values defining the mapping have an opacity equal to 1. ...
a simple class to control print indentation
abstract superclass for arrays of numeric data
int UsingLogScale() override
This should return 1 if the subclass is using log scale for mapping scalars to colors.
dynamic, self-adjusting array of unsigned char
vtkSetMacro(IgnoreDriverBugs, bool)
When set known driver bugs are ignored during driver feature detection.
vtkIdType GetNumberOfAvailableColors() override
Get the number of available colors for mapping to.
a combination of vtkColorTransferFunction and vtkLookupTable.
Defines a transfer function for mapping a property to an RGB color value.
virtual void Build()
Perform any processing required (if any) before processing scalars.
vtkBooleanMacro(IgnoreDriverBugs, bool)
When set known driver bugs are ignored during driver feature detection.