15 #ifndef __vtkMRMLDisplayNode_h 16 #define __vtkMRMLDisplayNode_h 24 class vtkAlgorithmOutput;
41 void PrintSelf(ostream& os, vtkIndent indent) VTK_OVERRIDE;
46 PointsRepresentation = 0,
54 FlatInterpolation = 0,
72 UseManualScalarRange = 0,
78 NUM_SCALAR_RANGE_FLAGS
79 } ScalarRangeFlagType;
83 static const char* GetScalarRangeFlagTypeAsString(
int flag);
86 static int GetScalarRangeFlagTypeFromString(
const char* name);
98 virtual void WriteXML(ostream& of,
int indent) VTK_OVERRIDE;
107 void *callData) VTK_OVERRIDE;
114 virtual
void UpdateReferences() VTK_OVERRIDE;
117 virtual
void UpdateScene(
vtkMRMLScene *scene) VTK_OVERRIDE;
120 virtual
void UpdateReferenceID(const
char *oldID, const
char *newID) VTK_OVERRIDE;
124 vtkSetVector3Macro(Color,
double);
127 vtkGetVector3Macro(Color,
double);
131 vtkSetVector3Macro(EdgeColor,
double);
134 vtkGetVector3Macro(EdgeColor,
double);
138 vtkSetVector3Macro(SelectedColor,
double);
141 vtkGetVector3Macro(SelectedColor,
double);
145 vtkSetMacro(SelectedAmbient,
double);
148 vtkGetMacro(SelectedAmbient,
double);
152 vtkSetMacro(SelectedSpecular,
double);
155 vtkGetMacro(SelectedSpecular,
double);
159 vtkSetMacro(PointSize,
double);
162 vtkGetMacro(PointSize,
double);
166 vtkSetMacro(LineWidth,
double);
169 vtkGetMacro(LineWidth,
double);
173 vtkSetMacro(Representation,
int);
176 vtkGetMacro(Representation,
int);
180 vtkSetMacro(Opacity,
double);
183 vtkGetMacro(Opacity,
double);
187 vtkSetMacro(SliceIntersectionOpacity,
double);
190 vtkGetMacro(SliceIntersectionOpacity,
double);
194 vtkSetMacro(Ambient,
double);
197 vtkGetMacro(Ambient,
double);
201 vtkSetMacro(Diffuse,
double);
204 vtkGetMacro(Diffuse,
double);
208 vtkSetMacro(Specular,
double);
211 vtkGetMacro(Specular,
double);
215 vtkSetMacro(Power,
double);
218 vtkGetMacro(Power,
double);
222 vtkSetMacro(Visibility,
int);
225 vtkGetMacro(Visibility,
int);
228 vtkBooleanMacro(Visibility,
int);
234 virtual
bool GetVisibility(const
char* viewNodeID);
238 vtkSetMacro(EdgeVisibility,
int);
239 vtkBooleanMacro(EdgeVisibility,
int);
242 vtkGetMacro(EdgeVisibility,
int);
246 vtkSetMacro(Clipping,
int);
249 vtkGetMacro(Clipping,
int);
252 vtkBooleanMacro(Clipping,
int);
257 vtkSetMacro(SliceIntersectionVisibility,
int);
261 vtkGetMacro(SliceIntersectionVisibility,
int);
265 vtkBooleanMacro(SliceIntersectionVisibility,
int);
269 vtkSetMacro(SliceIntersectionThickness,
int);
272 vtkGetMacro(SliceIntersectionThickness,
int);
277 vtkSetMacro(FrontfaceCulling,
int);
281 vtkGetMacro(FrontfaceCulling,
int);
284 vtkBooleanMacro(FrontfaceCulling,
int);
288 vtkSetMacro(BackfaceCulling,
int);
292 vtkGetMacro(BackfaceCulling,
int);
295 vtkBooleanMacro(BackfaceCulling,
int);
300 vtkSetMacro(Lighting,
int);
304 vtkGetMacro(Lighting,
int);
307 vtkBooleanMacro(Lighting,
int);
311 vtkSetMacro(Interpolation,
int);
314 vtkGetMacro(Interpolation,
int);
318 vtkSetMacro(Shading,
int);
321 vtkGetMacro(Shading,
int);
326 vtkSetMacro(ScalarVisibility,
int);
330 vtkGetMacro(ScalarVisibility,
int);
333 vtkBooleanMacro(ScalarVisibility,
int);
338 vtkSetMacro(VectorVisibility,
int);
342 vtkGetMacro(VectorVisibility,
int);
345 vtkBooleanMacro(VectorVisibility,
int);
350 vtkSetMacro(TensorVisibility,
int);
354 vtkGetMacro(TensorVisibility,
int);
357 vtkBooleanMacro(TensorVisibility,
int);
363 void SetAutoScalarRange(
int b);
368 int GetAutoScalarRange();
372 void AutoScalarRangeOn();
373 void AutoScalarRangeOff();
377 vtkSetVector2Macro(ScalarRange,
double);
380 vtkGetVector2Macro(ScalarRange,
double);
384 vtkSetMacro(ScalarRangeFlag,
int);
387 vtkGetMacro(ScalarRangeFlag,
int);
391 virtual
void SetTextureImageDataConnection(vtkAlgorithmOutput *ImageDataConnection);
394 vtkGetObjectMacro(TextureImageDataConnection, vtkAlgorithmOutput);
399 vtkSetMacro(InterpolateTexture,
int);
403 vtkGetMacro(InterpolateTexture,
int);
406 vtkBooleanMacro(InterpolateTexture,
int);
410 virtual
void SetAndObserveColorNodeID(const
char *ColorNodeID);
414 void SetAndObserveColorNodeID(const
std::
string& ColorNodeID);
417 vtkGetStringMacro(ColorNodeID);
426 vtkSetStringMacro(ActiveScalarName);
429 vtkGetStringMacro(ActiveScalarName);
434 vtkSetMacro(ActiveAttributeLocation,
int);
437 vtkGetMacro(ActiveAttributeLocation,
int);
441 void AddViewNodeID(const
char* viewNodeID);
444 void RemoveViewNodeID(
char* viewNodeID);
447 void RemoveAllViewNodeIDs();
451 inline
int GetNumberOfViewNodeIDs()const;
455 const
char* GetNthViewNodeID(
unsigned int index);
459 inline
std::vector<
std::
string > GetViewNodeIDs()const;
463 bool IsViewNodeIDPresent(const
char* viewNodeID)const;
468 bool IsDisplayableInView(const
char* viewNodeID)const;
473 void SetDisplayableOnlyInView(const
char *viewNodeID);
477 void SetViewNodeIDs(const
std::vector<
std::
string >& viewNodeIDs);
480 static const
char* GetAttributeLocationAsString(
int id);
483 static
int GetAttributeLocationFromString(const
char* name);
502 vtkAlgorithmOutput *TextureImageDataConnection;
525 char *ActiveScalarName;
531 int ActiveAttributeLocation;
542 double SliceIntersectionOpacity;
567 double SelectedAmbient;
572 double SelectedSpecular;
633 int SliceIntersectionVisibility;
640 int SliceIntersectionThickness;
646 int FrontfaceCulling;
659 int ScalarVisibility;
666 int VectorVisibility;
673 int TensorVisibility;
679 int InterpolateTexture;
686 double ScalarRange[2];
703 double SelectedColor[3];
726 void SetColorNodeID(const
char*
id);
732 return static_cast<int>(this->ViewNodeIDs.size());
738 return this->ViewNodeIDs;
virtual void ReadXMLAttributes(const char **atts)
virtual void ProcessMRMLEvents(vtkObject *caller, unsigned long event, void *callData)
Propagate events generated in mrml.
std::vector< std::string > GetViewNodeIDs() const
virtual void SetSceneReferences()
Update the references of the node to the scene.
virtual void Copy(vtkMRMLNode *node)
Copy parameters (not including ID and Scene) from another node of the same type.
A set of MRML Nodes that supports serialization and undo/redo.
Abstract MRML node to represent color information.
virtual void WriteXML(ostream &of, int indent)
void PrintSelf(ostream &os, vtkIndent indent) VTK_OVERRIDE
Abstract class that contains graphical display properties for displayable nodes.
Abstract Superclass for all specific types of MRML nodes.