VTK  9.0.3
vtkCheckerboardRepresentation.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkCheckerboardRepresentation.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 vtkCheckerboardRepresentation_h
33 #define vtkCheckerboardRepresentation_h
34 
35 #include "vtkInteractionWidgetsModule.h" // For export macro
37 
39 class vtkImageActor;
41 
42 class VTKINTERACTIONWIDGETS_EXPORT vtkCheckerboardRepresentation : public vtkWidgetRepresentation
43 {
44 public:
49 
51 
55  void PrintSelf(ostream& os, vtkIndent indent) override;
57 
59 
63  vtkGetObjectMacro(Checkerboard, vtkImageCheckerboard);
65 
67 
70  void SetImageActor(vtkImageActor* imageActor);
71  vtkGetObjectMacro(ImageActor, vtkImageActor);
73 
75 
80  vtkSetClampMacro(CornerOffset, double, 0.0, 0.4);
81  vtkGetMacro(CornerOffset, double);
83 
84  enum
85  {
86  TopSlider = 0,
89  LeftSlider
90  };
91 
96  void SliderValueChanged(int sliderNum);
97 
99 
108  vtkGetObjectMacro(TopRepresentation, vtkSliderRepresentation3D);
109  vtkGetObjectMacro(RightRepresentation, vtkSliderRepresentation3D);
110  vtkGetObjectMacro(BottomRepresentation, vtkSliderRepresentation3D);
111  vtkGetObjectMacro(LeftRepresentation, vtkSliderRepresentation3D);
113 
115 
118  void BuildRepresentation() override;
119  void GetActors(vtkPropCollection*) override;
121  int RenderOverlay(vtkViewport* viewport) override;
122  int RenderOpaqueGeometry(vtkViewport* viewport) override;
126 
127 protected:
130 
131  // Instances that this class manipulates
134 
135  // The internal widgets for each side
140 
141  // The corner offset
142  double CornerOffset;
143 
144  // Direction index of image actor's plane normal
146 
147 private:
149  void operator=(const vtkCheckerboardRepresentation&) = delete;
150 };
151 
152 #endif
represent the vtkCheckerboardWidget
void SetImageActor(vtkImageActor *imageActor)
Specify an instance of vtkImageActor to decorate.
int RenderOverlay(vtkViewport *viewport) override
void GetActors(vtkPropCollection *) override
For some exporters and other other operations we must be able to collect all the actors or volumes.
void SetCheckerboard(vtkImageCheckerboard *chkrbrd)
Specify an instance of vtkImageCheckerboard to manipulate.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
int RenderOpaqueGeometry(vtkViewport *viewport) override
WARNING: INTERNAL METHOD - NOT INTENDED FOR GENERAL USE DO NOT USE THESE METHODS OUTSIDE OF THE RENDE...
vtkTypeBool HasTranslucentPolygonalGeometry() override
WARNING: INTERNAL METHOD - NOT INTENDED FOR GENERAL USE DO NOT USE THESE METHODS OUTSIDE OF THE RENDE...
void SliderValueChanged(int sliderNum)
This method is invoked by the vtkCheckerboardWidget() when a value of some slider has changed.
void SetRightRepresentation(vtkSliderRepresentation3D *)
vtkSliderRepresentation3D * RightRepresentation
vtkSliderRepresentation3D * LeftRepresentation
void SetLeftRepresentation(vtkSliderRepresentation3D *)
int RenderTranslucentPolygonalGeometry(vtkViewport *viewport) override
void BuildRepresentation() override
Methods required by superclass.
void SetBottomRepresentation(vtkSliderRepresentation3D *)
vtkSliderRepresentation3D * TopRepresentation
~vtkCheckerboardRepresentation() override
void ReleaseGraphicsResources(vtkWindow *w) override
WARNING: INTERNAL METHOD - NOT INTENDED FOR GENERAL USE Release any graphics resources that are being...
vtkSliderRepresentation3D * BottomRepresentation
void SetTopRepresentation(vtkSliderRepresentation3D *)
Set and get the instances of vtkSliderRepresention used to implement this representation.
static vtkCheckerboardRepresentation * New()
Instantiate class.
draw an image in a rendered 3D scene
Definition: vtkImageActor.h:43
show two images at once using a checkboard pattern
a simple class to control print indentation
Definition: vtkIndent.h:34
an ordered list of Props
provide the representation for a vtkSliderWidget with a 3D skin
abstract specification for Viewports
Definition: vtkViewport.h:45
abstract class defines interface between the widget and widget representation classes
window superclass for vtkRenderWindow
Definition: vtkWindow.h:38
int vtkTypeBool
Definition: vtkABI.h:69