VTK  9.3.0
vtkImageStack.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-License-Identifier: BSD-3-Clause
32 #ifndef vtkImageStack_h
33 #define vtkImageStack_h
34 
35 #include "vtkImageSlice.h"
36 #include "vtkRenderingImageModule.h" // For export macro
37 
38 VTK_ABI_NAMESPACE_BEGIN
40 class vtkImageProperty;
41 class vtkImageMapper3D;
42 class vtkCollection;
43 
44 class VTKRENDERINGIMAGE_EXPORT vtkImageStack : public vtkImageSlice
45 {
46 public:
47  vtkTypeMacro(vtkImageStack, vtkImageSlice);
48  void PrintSelf(ostream& os, vtkIndent indent) override;
49  static vtkImageStack* New();
50 
55  void AddImage(vtkImageSlice* prop);
56 
62 
67 
71  vtkImageSliceCollection* GetImages() { return this->Images; }
72 
74 
78  vtkSetMacro(ActiveLayer, int);
79  int GetActiveLayer() { return this->ActiveLayer; }
81 
88 
93 
98 
100 
103  double* GetBounds() override;
104  void GetBounds(double bounds[6]) { this->vtkProp3D::GetBounds(bounds); }
106 
110  vtkMTimeType GetMTime() override;
111 
119 
123  void ShallowCopy(vtkProp* prop) override;
124 
131 
133 
136  int RenderOverlay(vtkViewport* viewport) override;
137  int RenderOpaqueGeometry(vtkViewport* viewport) override;
140 
145 
149  void ReleaseGraphicsResources(vtkWindow* win) override;
150 
152 
156  void InitPathTraversal() override;
158  int GetNumberOfPaths() override;
160 
166  void BuildPaths(vtkAssemblyPaths* paths, vtkAssemblyPath* path) override;
167 
168 protected:
170  ~vtkImageStack() override;
171 
173  void SetProperty(vtkImageProperty* property);
174 
175  void PokeMatrices(vtkMatrix4x4* matrix);
176  void UpdatePaths();
177 
182 
183 private:
184  vtkImageStack(const vtkImageStack&) = delete;
185  void operator=(const vtkImageStack&) = delete;
186 };
187 
188 VTK_ABI_NAMESPACE_END
189 #endif
a list of nodes that form an assembly path
a list of lists of props representing an assembly hierarchy
create and manipulate ordered lists of objects
Definition: vtkCollection.h:45
abstract class for mapping images to the screen
image display properties
a sorted list of image slice objects
represents an image in a 3D scene
Definition: vtkImageSlice.h:48
manages a stack of composited images
Definition: vtkImageStack.h:45
void RemoveImage(vtkImageSlice *prop)
Remove an image from the stack.
vtkAssemblyPath * GetNextPath() override
Methods for traversing the stack as if it was an assembly.
void BuildPaths(vtkAssemblyPaths *paths, vtkAssemblyPath *path) override
WARNING: INTERNAL METHOD - NOT INTENDED FOR GENERAL USE DO NOT USE THIS METHOD OUTSIDE OF THE RENDERI...
int RenderOpaqueGeometry(vtkViewport *viewport) override
Support the standard render methods.
int GetActiveLayer()
Set the active layer number.
Definition: vtkImageStack.h:79
void SetMapper(vtkImageMapper3D *mapper)
~vtkImageStack() override
void UpdatePaths()
vtkTypeBool HasImage(vtkImageSlice *prop)
Check if an image is present.
void InitPathTraversal() override
Methods for traversing the stack as if it was an assembly.
void PokeMatrices(vtkMatrix4x4 *matrix)
void ShallowCopy(vtkProp *prop) override
Shallow copy of this prop.
void GetBounds(double bounds[6])
Get the combined bounds of all of the images.
vtkImageSliceCollection * GetImages()
Get the list of images as a vtkImageSliceCollection.
Definition: vtkImageStack.h:71
vtkImageSlice * GetActiveImage()
Get the active image.
vtkMTimeType GetRedrawMTime() override
Return the mtime of anything that would cause the rendered image to appear differently.
vtkTypeBool HasTranslucentPolygonalGeometry() override
Does this prop have some translucent polygonal geometry?
int RenderOverlay(vtkViewport *viewport) override
Support the standard render methods.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkImageProperty * GetProperty() override
Get the property for the currently active image.
static vtkImageStack * New()
void ReleaseGraphicsResources(vtkWindow *win) override
Release any resources held by this prop.
int GetNumberOfPaths() override
Methods for traversing the stack as if it was an assembly.
double * GetBounds() override
Get the combined bounds of all of the images.
int RenderTranslucentPolygonalGeometry(vtkViewport *viewport) override
Support the standard render methods.
vtkImageSliceCollection * Images
vtkTimeStamp PathTime
void SetProperty(vtkImageProperty *property)
vtkMTimeType GetMTime() override
Return the max MTime of all the images.
void AddImage(vtkImageSlice *prop)
Add an image to the stack.
vtkImageMapper3D * GetMapper() override
Get the mapper for the currently active image.
vtkCollection * ImageMatrices
void GetImages(vtkPropCollection *)
For some exporters and other other operations we must be able to collect all the actors,...
a simple class to control print indentation
Definition: vtkIndent.h:38
represent and manipulate 4x4 transformation matrices
Definition: vtkMatrix4x4.h:40
double * GetBounds() override=0
Return a reference to the Prop3D's composite transform.
an ordered list of Props
abstract superclass for all actors, volumes and annotations
Definition: vtkProp.h:55
record modification and/or execution time
Definition: vtkTimeStamp.h:34
abstract specification for Viewports
Definition: vtkViewport.h:54
window superclass for vtkRenderWindow
Definition: vtkWindow.h:37
int vtkTypeBool
Definition: vtkABI.h:64
vtkTypeUInt32 vtkMTimeType
Definition: vtkType.h:270