VR-Vantage API Documentation
Home
Modules
Namespaces
Classes
Files
Examples
Tutorials
File List
File Members
include
vrvCore
DtModelClasses.hpp
Go to the documentation of this file.
1
/******************************************************************************
2
** Copyright (c) 2007 MAK Technologies, Inc.
3
** All rights reserved.
4
******************************************************************************/
5
7
8
#ifndef DtModelClasses_H_
9
#define DtModelClasses_H_
10
11
#include <
vrvCore/vrvCore.h
>
12
13
#include <
vrvCore/DtAgent.h
>
14
#include <
vrvCore/DtModelAgent.hpp
>
15
16
namespace
makVrv
17
{
18
20
class
DT_DLL_VRVCORE
DtModelAgentImplementation
:
public
virtual
DtModelAgent
21
{
22
public
:
24
DtModelAgentImplementation
();
25
27
virtual
~
DtModelAgentImplementation
();
28
//Set the model definition to be used to create the model instance.
29
virtual
void
setModelDefinition(
const
std::string& definitionName);
30
31
//Save the model contents to a file.
32
virtual
void
saveModelToFile(
const
std::string& filename);
33
35
virtual
void
setVisible(
bool
isVisible);
36
37
38
virtual
void
setContributesToBound(
bool
trueOrFalse);
39
40
41
virtual
void
enableColorBlending(
bool
b);
42
43
44
virtual
void
setBlendColor(
float
r,
float
g,
float
b,
float
a);
45
46
47
virtual
void
setColor(
float
r,
float
g,
float
b,
float
a);
48
49
50
protected
:
51
virtual
DtModel
* findObjectAsDtModel();
52
53
};
54
55
}
56
57
#include <
vrvCore/DtAgentDefinition.h
>
58
#include <
vrvCore/DtModel.h
>
59
60
namespace
makVrv
61
{
62
64
class
DT_DLL_VRVCORE
DtModelClassDefinition
:
public
makVrv::DtAgentDefinition
<DtModel>
65
{
66
public
:
68
DtModelClassDefinition
(
const
std::string& className =
"DtModel"
);
69
71
virtual
~
DtModelClassDefinition
();
72
74
enum
FunctionIds
75
{
76
function_setModelDefinition
,
77
function_saveModelToFile
,
78
function_setVisible
,
79
function_setContributesToBound
,
80
function_enableColorBlending
,
81
function_setBlendColor
,
82
function_setColor
,
83
end_FunctionIds
84
};
85
86
};
87
88
}
89
#include <
vrvCore/DtAgentCreator.h
>
90
#include <
vrvCore/DtAgentFactory.h
>
91
92
namespace
makVrv
93
{
94
95
class
DtModelClassDefinition;
96
98
class
DT_DLL_VRVCORE
DtModelClassesCreator
:
public
makVrv::DtAgentCreator
99
{
100
public
:
101
103
DtModelClassesCreator
();
104
106
virtual
~
DtModelClassesCreator
();
107
108
static
makVrv::DtAgentCreator
* create();
109
111
virtual
makVrv::DtAgent
* createAgent(
makVrv::DtAgentManagerInterface
& sceneInterface);
112
114
virtual
makVrv::DtAgentUpdateResolverInterface
* createResolver(
makVrv::DtDe
& de,
makVrv::DtUniqueID
id
);
115
116
protected
:
117
DtModelClassDefinition
*
myDefinition
;
118
119
static
bool
theRegisteredFlag
;
120
static
makVrv::DtAgentFactory::DtAutoUnregistrar
theAutoUnregistrar
;
121
};
122
123
}
124
125
#endif
126
Copyright © 2005-2013 VT MÄK Inc. All Rights Reserved (
www.mak.com
)