Go to the documentation of this file.
10 #ifndef vtk_m_cont_ColorTable_h
11 #define vtk_m_cont_ColorTable_h
16 #include <vtkm/cont/vtkm_cont_export.h>
33 struct ColorTableInternals;
91 std::shared_ptr<detail::ColorTableInternals>
Internals;
189 const std::string& name,
192 const std::vector<vtkm::Float64>& rgbPoints,
193 const std::vector<vtkm::Float64>& alphaPoints = { 0.0, 1.0, 0.5, 0.0, 1.0, 1.0, 0.5, 0.0 });
198 ColorTable& operator=(
const ColorTable&) =
default;
199 ColorTable(
const ColorTable&) =
default;
201 const std::string& GetName()
const;
202 void SetName(
const std::string& name);
211 static std::set<std::string> GetPresets();
241 bool LoadPreset(
const std::string& name);
248 ColorTable MakeDeepCopy();
261 void SetClamping(
bool state);
262 bool GetClamping()
const;
293 void ReverseColors();
381 return AddPointAlpha(x, alpha, 0.5f, 0.0f);
406 return AddSegmentAlpha(x1, alpha1, x2, alpha2, mid_sharp, mid_sharp);
585 void UpdateArrayHandles()
const;
589 #endif //vtk_m_cont_ColorTable_h
Manages an array-worth of data.
Definition: ArrayHandle.h:283
Groups connected points that have the same field value.
Definition: Atomic.h:19
Color Table for coloring arbitrary fields.
Definition: cont/ColorTable.h:89
vtkm::Int32 AddPointAlpha(vtkm::Float64 x, vtkm::Float32 alpha)
Adds a point to the opacity function.
Definition: cont/ColorTable.h:379
void SetClampingOff()
Definition: cont/ColorTable.h:260
vtkm::Int32 Id
Represents an ID (index into arrays).
Definition: Types.h:191
A token to hold the scope of an ArrayHandle or other object.
Definition: Token.h:35
void SetClampingOn()
If clamping is disabled values that lay out side the color table range are colored based on Below and...
Definition: cont/ColorTable.h:259
vtkm::Int32 AddSegmentAlpha(vtkm::Float64 x1, vtkm::Float32 alpha1, vtkm::Float64 x2, vtkm::Float32 alpha2)
Add a line segment to the opacity function.
Definition: cont/ColorTable.h:400
Color Sample Table used with vtkm::cont::ColorTable for fast coloring.
Definition: ColorTableSamples.h:32
Definition: exec/ColorTable.h:34
Base ExecutionObjectBase for execution objects to inherit from so that you can use an arbitrary objec...
Definition: ExecutionObjectBase.h:31
Definition: DeviceAdapterTag.h:52
Color Sample Table used with vtkm::cont::ColorTable for fast coloring.
Definition: ColorTableSamples.h:51
Preset
Definition: cont/ColorTable.h:94
float Float32
Definition: Types.h:154
int32_t Int32
Definition: Types.h:160
double Float64
Definition: Types.h:155
std::shared_ptr< detail::ColorTableInternals > Internals
Definition: cont/ColorTable.h:91
ColorSpace
Definition: exec/ColorTable.h:18
Represent a continuous scalar range of values.
Definition: Range.h:31