VTK
9.1.0
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
Rendering
ContextOpenGL2
vtkOpenGLPropItem.h
Go to the documentation of this file.
1
/*=========================================================================
2
3
Program: Visualization Toolkit
4
Module: vtkOpenGLPropItem.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
27
#ifndef vtkOpenGLPropItem_h
28
#define vtkOpenGLPropItem_h
29
30
#include "
vtkNew.h
"
// for vtkNew
31
#include "
vtkPropItem.h
"
32
#include "vtkRenderingContextOpenGL2Module.h"
// For export macro
33
34
class
vtkCamera
;
35
36
class
VTKRENDERINGCONTEXTOPENGL2_EXPORT
vtkOpenGLPropItem
:
public
vtkPropItem
37
{
38
public
:
39
static
vtkOpenGLPropItem
*
New
();
40
vtkTypeMacro(
vtkOpenGLPropItem
,
vtkPropItem
);
41
void
PrintSelf
(ostream& os,
vtkIndent
indent)
override
;
42
43
bool
Paint
(
vtkContext2D
* painter)
override
;
44
45
protected
:
46
vtkOpenGLPropItem
();
47
~vtkOpenGLPropItem
()
override
;
48
49
// Sync the active vtkCamera with the GL state set by the painter.
50
void
UpdateTransforms
()
override
;
51
52
// Restore the vtkCamera state.
53
void
ResetTransforms
()
override
;
54
55
private
:
56
vtkNew<vtkCamera>
CameraCache;
57
vtkContext2D
* Painter;
58
59
vtkOpenGLPropItem
(
const
vtkOpenGLPropItem
&) =
delete
;
60
void
operator=(
const
vtkOpenGLPropItem
&) =
delete
;
61
};
62
63
#endif
// vtkOpenGLPropItem_h
vtkCamera
a virtual camera for 3D rendering
Definition:
vtkCamera.h:155
vtkContext2D
Class for drawing 2D primitives to a graphical context.
Definition:
vtkContext2D.h:73
vtkIndent
a simple class to control print indentation
Definition:
vtkIndent.h:113
vtkNew
Allocate and hold a VTK object.
Definition:
vtkNew.h:165
vtkOpenGLPropItem
Sync Context2D state with vtk camera.
Definition:
vtkOpenGLPropItem.h:37
vtkOpenGLPropItem::New
static vtkOpenGLPropItem * New()
vtkOpenGLPropItem::UpdateTransforms
void UpdateTransforms() override
vtkOpenGLPropItem::Paint
bool Paint(vtkContext2D *painter) override
Paint event for the item, called whenever the item needs to be drawn.
vtkOpenGLPropItem::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkOpenGLPropItem::ResetTransforms
void ResetTransforms() override
vtkOpenGLPropItem::vtkOpenGLPropItem
vtkOpenGLPropItem()
vtkOpenGLPropItem::~vtkOpenGLPropItem
~vtkOpenGLPropItem() override
vtkPropItem
Embed a vtkProp in a vtkContextScene.
Definition:
vtkPropItem.h:35
vtkNew.h
vtkPropItem.h
Generated on Fri Apr 21 2023 10:29:00 for VTK by
1.9.6