VR-Forces 4.7 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DtObserverSettingsLogic.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 2016 MAK Technologies, Inc.
3 ** All rights reserved.
4 ******************************************************************************/
5 
9 
10 #pragma once
11 
12 #include <vrvCoreQt/vrvCoreQt.h>
14 
15 namespace makVrv
16 {
17  class DtDe;
18  class DtObserverSettingsInterface;
19  class DtPersistenceControlsInterface;
20  class DtSettingsBackup;
21  class DtInputDriver;
22  class DtObserver;
23  class DtSensor;
24 
28  {
29  public:
30 
33  DtObserverSettingsInterface* observerModeEditorIf );
34 
36  virtual ~DtObserverSettingsLogic();
37 
39  virtual void setSelectedObserver( const std::string& observerName );
40 
42  virtual void setSelectedObserverMode( const std::string& ObserverModeName );
43 
44  virtual void modelSetChanged( int modelSet );
45  virtual void sensorChanged( const std::string& sensor);
46  virtual void keyMapChanged( const std::string& keyMap );
47  virtual void projectionChanged( const std::string& projection );
48  virtual void settingChanged( int settingKey, bool value );
49 
51  virtual void setModelScaleFactor( int factor );
52 
54  virtual void setModelScaleType( DtObserverObject::ScaleType type );
55 
57  virtual void setMaxModelScaleFactor( double maxScaleFactor );
58 
60  virtual void setLinearSpeedGain( int gain );
61 
63  virtual void setRotationSpeedGain( int gain );
64 
66  virtual void setOrbitSpeedGain( int gain );
67 
69  virtual void setSpeedScalingMode(
71 
73  virtual void setSpeedScalingMslModeOffset(double offset);
74 
76  virtual void setCameraShakeIntensity(double intensity);
77 
79  virtual void setCameraShakeEnabled(bool enabled);
80 
81  virtual void createObserver( const std::string& ObserverName );
82  virtual void deleteObserver( const std::string& ObserverName );
83  virtual void renameObserver( const std::string& oldName, const std::string& newName );
84 
85  virtual void createObserverMode( const std::string& ObserverModeName );
86  virtual void deleteObserverMode( const std::string& ObserverModeName );
87  virtual void renameObserverMode( const std::string& oldName, const std::string& newName );
88 
89  protected:
90 
91  virtual void observerModesRestored(const DtSettingsBackup*);
92 
94  void setupValues();
95 
96  // called by setupValues, and also when projection or model set changes
97  // the update the settings pane
98  void setupSettings();
99 
100  void setupSpeedSliders();
101  void setupModelScaleFactorSlider();
102  void setupModelScaleTypeSelector();
103  void setupMaxModelScaleFactorSpinBox();
104 
105  void setupObserverList();
106  void setupObserverModeList();
107 
108  std::string projectionToString( bool is2D );
109  bool projectionFromString( const std::string& is2D );
110 
112  virtual void onExport();
113 
115  virtual void onExportSelected();
116 
119  virtual void onExportFilenameChosen(const std::string&, bool selected);
120 
123  virtual void onImport();
124 
127  virtual void onImportFilenameChosen(const std::string&);
128 
131  virtual void onMerge();
132 
135  virtual void onMergeFilenameChosen( const std::string& );
136 
137  virtual void updateDeleteEnabledState( const std::string& channelKeyToIgnore = "" );
138 
139  virtual void setCurrentObserverSelected();
140 
141  protected:
142  void slot_observerModeNameChanged( int modeId );
143  void slot_observerModeSettingChanged( int modeId );
144 
147  void slot_channelConfigurationModified();
148 
151  void slot_channelToBeDestroyed(const std::string& displayName,
152  const std::string& windowName, const std::string& channelName );
153 
156  void slot_channelConfigurationAdded();
157 
161  void slot_sensorAdded(DtSensor* sensor);
162 
166  void slot_sensorRemoved(DtSensor* sensor);
167 
171  void slot_sensorRenamed(DtSensor* sensor, const std::string& oldName);
172 
174  void slot_observerCreated( DtInputDriver* inputDriver,
175  DtObserver* observer );
176 
178  void slot_observerAboutToBeDestroyed( DtInputDriver* inputDriver,
179  DtObserver* observer );
180 
182  void slot_observerModeChanged( DtObserver* observer, int newObserverMode );
183 
184  protected:
189  // We need this so we don't make an observer that's being deleted the
190  // new selected observer
192  };
193 }

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)