VR-Forces 4.7 Class Documentation
Home
Modules
Namespaces
Classes
Files
Examples
Behavior Models
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Properties
Friends
Macros
Groups
Pages
include
vrvDiGuy
DtDiGuyModelInstance.h
Go to the documentation of this file.
1
/******************************************************************************
2
** Copyright (c) 2016 MAK Technologies, Inc.
3
** All rights reserved.
4
******************************************************************************/
5
9
10
#include <
vrvOsg/DtOsgModelInstance.h
>
11
12
#include <list>
13
#include <
vrvDiGuy/vrvDiGuy.h
>
14
#include <vector>
15
16
class
diguyCharacter;
17
class
diguyGraphicsLink
;
18
19
namespace
makVrv
20
{
21
22
class
DtSceneObject;
23
26
class
DT_DLL_VRVDIGUY
DtDiGuyModelInstance
:
public
DtOsgModelInstance
27
{
28
public
:
29
30
//Let the creator class make instances.
31
friend
class
DtDiGuyModelInstanceCreator
;
32
34
virtual
~
DtDiGuyModelInstance
();
35
38
virtual
bool
realize(
DtModelDefinition
& definition);
39
41
diguyCharacter* character();
42
43
virtual
void
setVisible(
bool
isVisible);
44
virtual
bool
getVisible
(){
return
myNodeVisible;}
45
48
virtual
void
updateBoundingBoxViaContents();
49
50
//this sets the final position post ground clamping/embarking transforms
51
virtual
void
setPosition(
const
DtVector
& pos);
52
53
//this sets the final Orientation post ground clamping/embarking transforms
54
virtual
void
setOrientation(
const
DtTaitBryan& ori);
55
56
osg::Node* sensorNode();
57
58
59
const
osg::Node* sensorNode()
const
;
60
61
62
virtual
void
setRootNode(osg::Node* n);
63
64
boost::signal<void (DtDiGuyModelInstance*)>
signal_diGuyModelInstanceChanged
;
65
boost::signal<void (DtDiGuyModelInstance*)>
signal_diGuyCharacterToBeDestroyed
;
66
67
struct
DtDiGuyShapeData
68
{
69
std::string
shapeClassType
;
70
std::string
shapeSetName
;
71
std::string
shapeMaterialSystemType
;
72
osg::Node *
shapeRootNode
;
73
};
74
75
typedef
std::vector<DtDiGuyShapeData>
ShapeDataVector
;
76
virtual
void
getShapeData(
ShapeDataVector
& shapeData);
77
78
virtual
void
setShapeTboData(osg::Node *shapeRootNode,
const
std::vector<float> &tboData);
79
80
protected
:
81
82
void
destroyCharacter();
83
85
DtDiGuyModelInstance
(
DtDe
& de);
86
87
protected
:
88
89
diguyCharacter*
myCharacter
;
90
91
bool
myNodeVisible
;
92
bool
myCanBeRecycled
;
93
bool
myCastsShadows
;
94
bool
myReceivesShadows
;
95
};
96
99
class
DT_DLL_VRVDIGUY
DtDiGuyModelInstanceCreator
:
public
DtModelInstanceCreator
100
{
101
public
:
102
104
static
void
registerCreator(
DtDe
& de);
105
107
virtual
~
DtDiGuyModelInstanceCreator
();
108
110
virtual
DtModelInstance
* create(
DtDe
& de);
111
112
protected
:
113
114
DtDiGuyModelInstanceCreator
();
115
116
};
117
}
Document ID: Generated on Fri Apr 26 21:53:14 EDT 2019 from SVN revision 197883
Copyright © 2005-2019 VT MAK. All Rights Reserved (
www.mak.com
)