VTK
vtkRayCastImageDisplayHelper.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkRayCastImageDisplayHelper.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 =========================================================================*/
15 
28 #ifndef vtkRayCastImageDisplayHelper_h
29 #define vtkRayCastImageDisplayHelper_h
30 
31 #include "vtkRenderingVolumeModule.h" // For export macro
32 #include "vtkObject.h"
33 
35 class vtkRenderer;
36 class vtkVolume;
37 class vtkWindow;
38 
39 class VTKRENDERINGVOLUME_EXPORT vtkRayCastImageDisplayHelper : public vtkObject
40 {
41 public:
44  void PrintSelf(ostream& os, vtkIndent indent) override;
45 
46  virtual void RenderTexture( vtkVolume *vol, vtkRenderer *ren,
47  int imageMemorySize[2],
48  int imageViewportSize[2],
49  int imageInUseSize[2],
50  int imageOrigin[2],
51  float requestedDepth,
52  unsigned char *image ) = 0;
53 
54  virtual void RenderTexture( vtkVolume *vol, vtkRenderer *ren,
55  int imageMemorySize[2],
56  int imageViewportSize[2],
57  int imageInUseSize[2],
58  int imageOrigin[2],
59  float requestedDepth,
60  unsigned short *image ) = 0;
61 
62  virtual void RenderTexture( vtkVolume *vol, vtkRenderer *ren,
64  float requestedDepth ) = 0;
65 
66  vtkSetClampMacro( PreMultipliedColors, vtkTypeBool, 0, 1 );
67  vtkGetMacro( PreMultipliedColors, vtkTypeBool );
68  vtkBooleanMacro( PreMultipliedColors, vtkTypeBool );
69 
70 
72 
78  vtkSetMacro( PixelScale, float );
79  vtkGetMacro( PixelScale, float );
81 
85  virtual void ReleaseGraphicsResources(vtkWindow *) { }
86 
87 protected:
89  ~vtkRayCastImageDisplayHelper() override;
90 
95 
96  float PixelScale;
97 
98 private:
100  void operator=(const vtkRayCastImageDisplayHelper&) = delete;
101 };
102 
103 #endif
104 
represents a volume (data & properties) in a rendered scene
Definition: vtkVolume.h:50
abstract base class for most VTK objects
Definition: vtkObject.h:59
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
virtual void ReleaseGraphicsResources(vtkWindow *)
Derived class should implemen this if needed.
abstract specification for renderers
Definition: vtkRenderer.h:63
helper class that draws the image to the screen
int vtkTypeBool
Definition: vtkABI.h:69
window superclass for vtkRenderWindow
Definition: vtkWindow.h:37
vtkTypeBool PreMultipliedColors
Have the colors already been multiplied by alpha?
a simple class to control print indentation
Definition: vtkIndent.h:39
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...
helper class for a ray cast image