VTK
9.3.1
Main Page
Related Pages
Topics
Namespaces
Classes
Files
File List
File Members
Rendering
VR
vtkOpenGLAvatar.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
11
#ifndef vtkOpenGLAvatar_h
12
#define vtkOpenGLAvatar_h
13
14
#include "
vtkAvatar.h
"
15
#include "
vtkNew.h
"
// for ivars
16
#include "vtkRenderingVRModule.h"
// For export macro
17
18
VTK_ABI_NAMESPACE_BEGIN
19
class
vtkOpenGLActor
;
20
class
vtkOpenGLPolyDataMapper
;
21
class
vtkOpenGLRenderer
;
22
class
vtkVRRay
;
23
class
vtkFlagpoleLabel
;
24
class
vtkTextProperty
;
25
26
class
VTKRENDERINGVR_EXPORT
vtkOpenGLAvatar
:
public
vtkAvatar
27
{
28
public
:
29
static
vtkOpenGLAvatar
*
New
();
30
vtkTypeMacro(
vtkOpenGLAvatar
,
vtkAvatar
);
31
void
PrintSelf
(ostream& os,
vtkIndent
indent)
override
;
32
36
int
RenderOpaqueGeometry
(
vtkViewport
* vp)
override
;
37
int
RenderTranslucentPolygonalGeometry
(
vtkViewport
* vp)
override
;
38
39
double
*
GetBounds
()
VTK_SIZEHINT
(6) override;
40
41
void
SetUseLeftHand(
bool
val) override;
42
void
SetUseRightHand(
bool
val) override;
43
void
SetShowHandsOnly(
bool
val) override;
44
45
// Set Ray parameters
46
void
SetLeftShowRay(
bool
v);
47
void
SetRightShowRay(
bool
v);
48
void
SetRayLength(
double
length);
49
50
void
SetLabel(const
char
* label);
51
vtkTextProperty
* GetLabelTextProperty();
52
53
protected:
54
vtkOpenGLAvatar
();
55
~
vtkOpenGLAvatar
() override;
56
57
// move the torso and arms based on head/hand inputs.
58
void
CalcBody();
59
60
vtkNew
<
vtkOpenGLPolyDataMapper
> HeadMapper;
61
vtkNew
<
vtkOpenGLActor
> HeadActor;
62
vtkNew
<
vtkOpenGLPolyDataMapper
> LeftHandMapper;
63
vtkNew
<
vtkOpenGLActor
> LeftHandActor;
64
vtkNew
<
vtkOpenGLPolyDataMapper
> RightHandMapper;
65
vtkNew
<
vtkOpenGLActor
> RightHandActor;
66
vtkNew
<
vtkOpenGLPolyDataMapper
> BodyMapper[NUM_BODY];
67
vtkNew
<
vtkOpenGLActor
> BodyActor[NUM_BODY];
68
69
vtkNew
<
vtkVRRay
> LeftRay;
70
vtkNew
<
vtkVRRay
> RightRay;
71
72
vtkNew
<
vtkFlagpoleLabel
> LabelActor;
73
74
private:
75
vtkOpenGLAvatar
(const
vtkOpenGLAvatar
&) = delete;
76
void
operator=(const
vtkOpenGLAvatar
&) = delete;
77
};
78
79
VTK_ABI_NAMESPACE_END
80
#endif
vtkAvatar
Renders head and hands for a user in VR.
Definition
vtkAvatar.h:22
vtkFlagpoleLabel
Renders a flagpole (line) with a label at the top that faces the camera.
Definition
vtkFlagpoleLabel.h:35
vtkIndent
a simple class to control print indentation
Definition
vtkIndent.h:29
vtkNew
Allocate and hold a VTK object.
Definition
vtkNew.h:51
vtkOpenGLActor
OpenGL actor.
Definition
vtkOpenGLActor.h:24
vtkOpenGLAvatar
OpenGL Avatar.
Definition
vtkOpenGLAvatar.h:27
vtkOpenGLAvatar::New
static vtkOpenGLAvatar * New()
vtkOpenGLAvatar::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkOpenGLAvatar::RenderTranslucentPolygonalGeometry
int RenderTranslucentPolygonalGeometry(vtkViewport *vp) override
Support the standard render methods.
vtkOpenGLAvatar::GetBounds
double * GetBounds() override
Return a reference to the Prop3D's composite transform.
vtkOpenGLAvatar::RenderOpaqueGeometry
int RenderOpaqueGeometry(vtkViewport *vp) override
Actual Avatar render method.
vtkOpenGLPolyDataMapper
PolyDataMapper using OpenGL to render.
Definition
vtkOpenGLPolyDataMapper.h:49
vtkOpenGLRenderer
OpenGL renderer.
Definition
vtkOpenGLRenderer.h:43
vtkTextProperty
represent text properties.
Definition
vtkTextProperty.h:26
vtkVRRay
VR device model.
Definition
vtkVRRay.h:25
vtkViewport
abstract specification for Viewports
Definition
vtkViewport.h:45
vtkAvatar.h
vtkNew.h
VTK_SIZEHINT
#define VTK_SIZEHINT(...)
Definition
vtkWrappingHints.h:36
Generated on Tue Oct 8 2024 00:00:00 for VTK by
1.12.0