VR-Forces 4.1 Class Documentation
Home
Modules
Namespaces
Classes
Files
Examples
Behavior Models
File List
File Members
include
vrvGlStudioShared
DtSharedCockpitSettings.h
Go to the documentation of this file.
1
/******************************************************************************
2
** Copyright (c) 2008 MAK Technologies, Inc.
3
** All rights reserved.
4
******************************************************************************/
5
/******************************************************************************
6
** $RCSfile: DtSharedCockpitSettings.h,v $ $Revision: 1.6 $ $State: Exp $
7
******************************************************************************/
8
12
#pragma once
13
#include <
vrvGlStudioShared/DtGlStudioShared.h
>
14
#include <
vrvGlStudioShared/DtGlStudioAttributeUpdaterFactory.h
>
15
#include <
makArchives/DtCockpitSettingsRecord.h
>
16
17
#include <
vrvCore/DtSharedSettings.h
>
18
#include <
vrvCore/DtUniqueID.h
>
19
#include <
vrvCore/DtRecordSettingsBackup.h
>
20
21
#include <string>
22
#include <vector>
23
24
class
DtEntityType;
25
26
namespace
makVrv
27
{
28
class
DtEntityTypeMapper;
29
class
DtEntityTypeMapperCreator;
30
class
DtModelDefinition;
31
class
DtDe;
32
class
DtObserver;
33
class
DtSharedCockpitSettings
;
34
35
typedef
DtSharedRecordSettingsBackup<DtSharedCockpitSettings, makArchives::DtCockpitSettingsRecord>
DtCockpitSettingsBackup
;
36
39
class
DT_DLL_VRVGLSTUDIOSHARED
DtSharedCockpitSettings
:
public
DtSharedSettings
40
{
41
public
:
42
45
friend
class
DtReadSettingsLock
<
DtSharedCockpitSettings
>;
46
friend
class
DtWriteSettingsLock
<
DtSharedCockpitSettings
>;
47
friend
class
DtSharedSettingsManager
;
48
52
static
std::string className();
53
55
virtual
~
DtSharedCockpitSettings
();
56
58
void
setCockpitMapper(
const
DtEntityTypeMapper
& cockpitTypeMapper);
59
61
void
setCockpitModelMapping(
const
DtEntityType& type,
const
std::string& definition);
62
64
const
std::vector<DtUnicode>& mapCockpitModelDefinition(
const
DtEntityType& type)
const
;
65
67
virtual
void
setDe(
DtDe
*);
68
70
const
DtModelDefinition
* findCockpitDefinition(
const
std::string& str)
const
;
71
73
virtual
DtEntityTypeMapper
* findMapperByName(
const
std::string& name);
74
virtual
const
DtEntityTypeMapper
* findMapperByName(
const
std::string& name)
const
;
75
77
virtual
DtEntityTypeMapper
& cockpitTypeMapper();
78
virtual
const
DtEntityTypeMapper
& cockpitTypeMapper()
const
;
79
81
virtual
void
setFromRecord(
const
makArchives::DtCockpitSettingsRecord
& rec);
82
84
virtual
void
getRecord(
makArchives::DtCockpitSettingsRecord
& rec )
const
;
85
87
virtual
void
mapperChanged(
const
DtEntityType& type,
const
DtUnicode
& value,
DtEntityTypeMapper
& mapper);
88
90
virtual
void
realizeCockpit(
DtObserver
* obs,
DtUniqueID
&
id
);
92
virtual
void
unrealizeCockpit(
DtObserver
* obs);
93
95
virtual
const
std::string& dataPath()
const
;
97
virtual
void
setDataPath(
const
std::string& path);
98
100
virtual
void
setCockpitsEnabled(
bool
enable);
102
virtual
bool
cockpitsEnabled()
const
;
103
105
virtual
void
hideEntity(
const
std::string& obsName);
107
virtual
void
unHideEntity(
const
std::string& obsName);
108
110
virtual
DtGlStudioAttributeUpdaterFactory
& updaterFactory();
111
113
virtual
bool
smoothingEnabled()
const
;
115
virtual
void
setSmoothingEnabled(
bool
smooth);
116
118
virtual
double
smoothingPeriod()
const
;
120
virtual
void
setSmoothingPeriod(
const
double
& period);
121
122
const
DtSettingsBackup
* settingsBackup()
const
123
{
124
return
mySettingsBackup;
125
}
126
127
DtSettingsBackup
* settingsBackup()
128
{
129
return
mySettingsBackup;
130
}
131
133
virtual
void
backup();
134
135
protected
:
136
138
DtSharedCockpitSettings
(
DtSharedSettingsManager
& manager);
139
140
//Empty vector, for returning the reference which will always be empty.
141
std::vector<DtUnicode>
myEmptyMappings
;
142
143
//Entity type mapping
144
DtEntityTypeMapper
*
myCockpitTypeMapper
;
145
std::string
myDataPath
;
146
bool
myCockpitsEnabled
;
147
bool
myCockpitSmoothingEnabled
;
148
double
myCockpitSmoothingPeriod
;
149
150
DtDe
*
myDe
;
151
152
DtGlStudioAttributeUpdaterFactory
myUpdaterFactory
;
153
DtCockpitSettingsBackup
*
mySettingsBackup
;
154
};
155
}
Document ID: Generated on Tue Jan 29 18:21:16 EST 2013 from SVN revision 123193
Copyright © 2005-2013 VT MÄK Inc. All Rights Reserved (
www.mak.com
)