VTK  9.0.1
vtkImageStack.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkImageStack.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 =========================================================================*/
32 #ifndef vtkImageStack_h
33 #define vtkImageStack_h
34 
35 #include "vtkImageSlice.h"
36 #include "vtkRenderingImageModule.h" // For export macro
37 
39 class vtkImageProperty;
40 class vtkImageMapper3D;
41 class vtkCollection;
42 
43 class VTKRENDERINGIMAGE_EXPORT vtkImageStack : public vtkImageSlice
44 {
45 public:
46  vtkTypeMacro(vtkImageStack, vtkImageSlice);
47  void PrintSelf(ostream& os, vtkIndent indent) override;
48  static vtkImageStack* New();
49 
54  void AddImage(vtkImageSlice* prop);
55 
61 
65  int HasImage(vtkImageSlice* prop);
66 
70  vtkImageSliceCollection* GetImages() { return this->Images; }
71 
73 
77  vtkSetMacro(ActiveLayer, int);
78  int GetActiveLayer() { return this->ActiveLayer; }
80 
87 
92 
97 
99 
102  double* GetBounds() override;
103  void GetBounds(double bounds[6]) { this->vtkProp3D::GetBounds(bounds); }
105 
109  vtkMTimeType GetMTime() override;
110 
118 
122  void ShallowCopy(vtkProp* prop) override;
123 
130 
132 
135  int RenderOverlay(vtkViewport* viewport) override;
136  int RenderOpaqueGeometry(vtkViewport* viewport) override;
139 
144 
148  void ReleaseGraphicsResources(vtkWindow* win) override;
149 
151 
155  void InitPathTraversal() override;
157  int GetNumberOfPaths() override;
159 
165  void BuildPaths(vtkAssemblyPaths* paths, vtkAssemblyPath* path) override;
166 
167 protected:
169  ~vtkImageStack() override;
170 
172  void SetProperty(vtkImageProperty* property);
173 
174  void PokeMatrices(vtkMatrix4x4* matrix);
175  void UpdatePaths();
176 
181 
182 private:
183  vtkImageStack(const vtkImageStack&) = delete;
184  void operator=(const vtkImageStack&) = delete;
185 };
186 
187 #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:53
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:47
manages a stack of composited images
Definition: vtkImageStack.h:44
void RemoveImage(vtkImageSlice *prop)
Remove an image from the stack.
vtkAssemblyPath * GetNextPath() override
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
WARNING: INTERNAL METHOD - NOT INTENDED FOR GENERAL USE DO NOT USE THESE METHODS OUTSIDE OF THE RENDE...
int GetActiveLayer()
Definition: vtkImageStack.h:78
void SetMapper(vtkImageMapper3D *mapper)
~vtkImageStack() override
void UpdatePaths()
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])
vtkImageSliceCollection * GetImages()
Get the list of images as a vtkImageSliceCollection.
Definition: vtkImageStack.h:70
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
double * GetBounds() override
Get the combined bounds of all of the images.
int RenderTranslucentPolygonalGeometry(vtkViewport *viewport) override
vtkImageSliceCollection * Images
vtkTimeStamp PathTime
void SetProperty(vtkImageProperty *property)
int HasImage(vtkImageSlice *prop)
Check if an image is present.
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:34
represent and manipulate 4x4 transformation matrices
Definition: vtkMatrix4x4.h:36
double * GetBounds() override=0
Get the bounds for this Prop as (Xmin,Xmax,Ymin,Ymax,Zmin,Zmax).
an ordered list of Props
abstract superclass for all actors, volumes and annotations
Definition: vtkProp.h:54
record modification and/or execution time
Definition: vtkTimeStamp.h:33
abstract specification for Viewports
Definition: vtkViewport.h:45
window superclass for vtkRenderWindow
Definition: vtkWindow.h:38
int vtkTypeBool
Definition: vtkABI.h:69
vtkTypeUInt32 vtkMTimeType
Definition: vtkType.h:293