VTK
vtkImageProperty.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkImageProperty.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
34 #ifndef vtkImageProperty_h
35 #define vtkImageProperty_h
36 
37 #include "vtkRenderingCoreModule.h" // For export macro
38 #include "vtkObject.h"
39 
40 class vtkScalarsToColors;
41 
42 class VTKRENDERINGCORE_EXPORT vtkImageProperty : public vtkObject
43 {
44 public:
45  vtkTypeMacro(vtkImageProperty,vtkObject);
46  void PrintSelf(ostream& os, vtkIndent indent) override;
47 
51  static vtkImageProperty *New();
52 
56  void DeepCopy(vtkImageProperty *p);
57 
59 
62  vtkSetMacro(ColorWindow, double);
63  vtkGetMacro(ColorWindow, double);
65 
67 
70  vtkSetMacro(ColorLevel, double);
71  vtkGetMacro(ColorLevel, double);
73 
75 
80  virtual void SetLookupTable(vtkScalarsToColors *lut);
81  vtkGetObjectMacro(LookupTable, vtkScalarsToColors);
83 
85 
90  vtkSetMacro(UseLookupTableScalarRange, vtkTypeBool);
91  vtkGetMacro(UseLookupTableScalarRange, vtkTypeBool);
92  vtkBooleanMacro(UseLookupTableScalarRange, vtkTypeBool);
94 
96 
102  vtkSetClampMacro(Opacity, double, 0.0, 1.0);
103  vtkGetMacro(Opacity, double);
105 
107 
110  vtkSetClampMacro(Ambient, double, 0.0, 1.0);
111  vtkGetMacro(Ambient, double);
113 
115 
118  vtkSetClampMacro(Diffuse, double, 0.0, 1.0);
119  vtkGetMacro(Diffuse, double);
121 
123 
126  vtkSetClampMacro(InterpolationType, int,
128  vtkGetMacro(InterpolationType, int);
130  this->SetInterpolationType(VTK_NEAREST_INTERPOLATION); };
132  this->SetInterpolationType(VTK_LINEAR_INTERPOLATION); };
134  this->SetInterpolationType(VTK_CUBIC_INTERPOLATION); };
135  virtual const char *GetInterpolationTypeAsString();
137 
139 
143  vtkSetMacro(LayerNumber, int);
145  { return this->LayerNumber; }
147 
149 
153  vtkSetMacro(Checkerboard, vtkTypeBool);
154  vtkBooleanMacro(Checkerboard, vtkTypeBool);
155  vtkGetMacro(Checkerboard, vtkTypeBool);
157 
159 
162  vtkSetVector2Macro(CheckerboardSpacing, double);
163  vtkGetVector2Macro(CheckerboardSpacing, double);
165 
167 
171  vtkSetVector2Macro(CheckerboardOffset, double);
172  vtkGetVector2Macro(CheckerboardOffset, double);
174 
176 
182  vtkSetMacro(Backing, vtkTypeBool);
183  vtkBooleanMacro(Backing, vtkTypeBool);
184  vtkGetMacro(Backing, vtkTypeBool);
186 
188 
191  vtkSetVector3Macro(BackingColor, double);
192  vtkGetVector3Macro(BackingColor, double);
194 
199  vtkMTimeType GetMTime() override;
200 
201 protected:
203  ~vtkImageProperty() override;
204 
206  double ColorWindow;
207  double ColorLevel;
211  double Opacity;
212  double Ambient;
213  double Diffuse;
215  double CheckerboardSpacing[2];
216  double CheckerboardOffset[2];
218  double BackingColor[3];
219 
220 private:
221  vtkImageProperty(const vtkImageProperty&) = delete;
222  void operator=(const vtkImageProperty&) = delete;
223 };
224 
225 #endif
vtkScalarsToColors * LookupTable
int GetLayerNumber()
Set the layer number.
abstract base class for most VTK objects
Definition: vtkObject.h:59
void SetInterpolationTypeToCubic()
The interpolation type (default: nearest neighbor).
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkTypeUInt32 vtkMTimeType
Definition: vtkType.h:302
#define VTK_LINEAR_INTERPOLATION
image display properties
#define VTK_CUBIC_INTERPOLATION
int vtkTypeBool
Definition: vtkABI.h:69
Superclass for mapping scalar values to colors.
a simple class to control print indentation
Definition: vtkIndent.h:39
virtual vtkMTimeType GetMTime()
Return this object's modified time.
vtkTypeBool Checkerboard
vtkTypeBool UseLookupTableScalarRange
void SetInterpolationTypeToLinear()
The interpolation type (default: nearest neighbor).
void SetInterpolationTypeToNearest()
The interpolation type (default: nearest neighbor).
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...
#define VTK_NEAREST_INTERPOLATION