VR-Forces 5.0.2 Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
entityControlPanelWidgetLogic.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2019 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 
6 #pragma once
7 
9 
14 #include <vrvCore/DtUniqueID.h>
17 
18 #include <vrftasks/taskTypes.h>
19 #include <vrfutil/rwAirSpeedType.h>
20 
21 class DtEntityType;
22 class DtSimMessage;
23 class DtSetDataRequest;
24 class DtSimTask;
25 
26 namespace makVrv
27 {
28  class DtDe;
29  class DtSimObjectEntry;
30 }
31 
32 namespace makVrf
33 {
34  class DtEntityControlPanelWidgetInterface;
35 
38 
40  {
41  public:
43 
44  //DTOR
46 
47  public:
48 
50  virtual void updateOnSelectionChanged();
51  virtual void updateOnDataChanged();
52 
53  virtual void requestHeading(double value, bool defaultChangeRate,
54  const std::set<makVrv::DtUniqueID>& idSet = std::set<makVrv::DtUniqueID>());
55  virtual void requestAltitude(double value, bool defaultChangeRate,
56  const std::set<makVrv::DtUniqueID>& idSet = std::set<makVrv::DtUniqueID>());
57  virtual void requestSpeed(double value, bool defaultChangeRate, DtAirSpeedType airSpeedType,
58  const std::set<makVrv::DtUniqueID>& idSet = std::set<makVrv::DtUniqueID>());
59 
60  virtual void changeTurnDirection(int turnDirection);
61 
62  virtual void changeAirSpeedType(DtAirSpeedType type);
63 
65  virtual void enableUpdateRequestedHeading();
66 
68  virtual void requestStationaryEntitiesHeading(const std::set<makVrv::DtUniqueID>& idSet = std::set<makVrv::DtUniqueID>());
69 
70  void resetSelectedMapperKey();
71 
72  virtual void slot_onUnitChanged(const makVrv::DtUnicode& type, int newType, int old);
73  virtual void slot_onSimObjectEntryToBeRemoved(makVrv::DtSimObjectEntry& simEntry);
74 
76  virtual void blockSignals(bool);
77  bool signalsBlocked() const;
78 
79  protected:
80  virtual void initialize();
81 
82  virtual bool extractDataBasedOnEntityType(const DtEntityType& entityType, DtString& movementParamsType,
83  double& minSpeed, double& maxSpeed, double& minAlt, double& maxAlt, bool& enableAlt, double& maxTurn,
84  double& maxClimb, bool& isSupported);
85 
86  virtual void setDataFromMovementParamsType(const DtString& movementParamsType);
87 
88  virtual void sendSetDataRequest(const DtSetDataRequest& request, const std::set<makVrv::DtUniqueID>& idSet);
89  virtual void sendTaskRequest(const DtSimTask& task, const std::set<makVrv::DtUniqueID>& idSet);
90 
91  virtual void clear();
92  virtual void refreshDisplayUnitsLabels();
93  virtual void initializeHeadingUnits();
94  virtual void slot_displayUnitDecimalsChanged(const makVrv::DtUnicode& category, const makVrv::DtUnicode& type);
95 
97  virtual void setAltitudeRange(double minAlt, double maxAlt);
98  virtual void setActualAltitude(double altitude);
99  virtual void setRequestedAltitude(double altitude);
100  virtual void setTerrainHeight(double altitude);
101 
103  virtual void setSpeedRange(double minSpeed, double maxSpeed);
104  virtual void setActualSpeed(const DtVector& velocity);
105  virtual void setActualSpeed(double speed);
106  virtual void setRequestedSpeed(double speed);
107 
109  double convertNativeToDisplaySpeed(double speed);
110 
111  protected:
113  std::set<makVrv::DtUniqueID> mySelected;
114 
118 
121 
123  double myMaxClimb;
124 
127  double myMaxTurn;
128 
132 
134 
138 
140 
145 
147 
148  //Used only if myIsUsingAirSpeedType is true
151 
155  };
156 }
makVrv::DtSignalConnectionManager myConnectionManager
Definition: entityControlPanelWidgetLogic.h:116
Definition: entityMapperKey.h:23
A unicode string. DtUnicode stores a UTF-16 encoded unicode string. Code Point, a Unicode character...
Definition: DtUnicode.h:33
DtSetMessageType mySetSpeedTaskType
Definition: entityControlPanelWidgetLogic.h:126
bool myBlockSignals
Definition: entityControlPanelWidgetLogic.h:117
Contains makVrv:DtSelectionManager class.
DtEntityControlPanelWidgetInterface * myInterface
Definition: entityControlPanelWidgetLogic.h:115
makVrv::DtDe & myDe
Definition: entityControlPanelWidgetLogic.h:112
bool myUpdateRequestedAltitude
Definition: entityControlPanelWidgetLogic.h:143
double myMaxTurn
Definition: entityControlPanelWidgetLogic.h:127
bool mySelectedIsDestroyed
Definition: entityControlPanelWidgetLogic.h:119
bool myIsUsingAirSpeedType
Definition: entityControlPanelWidgetLogic.h:150
DtSimTaskMessageType myAltitudeTaskType
Definition: entityControlPanelWidgetLogic.h:122
Contains the DtSharedDisplayUnitsSettings class declaration.
DtSetDataRequest is an abstract base class from which real setDataRequests can derive. It manages the read/write capability; derived classes need only use and register read/writatble data types for derived information.
Definition: setDataRequest.h:41
int myTurnDirection
Definition: entityControlPanelWidgetLogic.h:146
bool myUpdateRequestedHeading
flags to update the requested UI from the network
Definition: entityControlPanelWidgetLogic.h:142
A DtSimObjectEntry is an entry for a persistent simulation object like an entity. ...
Definition: DtSimObjectEntry.h:22
bool myUpdateRequestedSpeed
Definition: entityControlPanelWidgetLogic.h:144
File: simMsg.h.
Definition: simMessage.h:35
Class to manage disconnection of boost connections on deletion.
Definition: DtSignalConnectionManager.h:20
DtSimTaskMessageType myHeadingTaskType
Definition: entityControlPanelWidgetLogic.h:125
#define DT_DLL_VRFGUICOMMONQT
Definition: vrfGuiCommonQt.h:20
Logic of the entity control panel widget: tasks executions, handling selection change, handling data updates and so on.
Definition: entityControlPanelWidgetLogic.h:39
This interface defines the required functions for the entity control panel widget.
Definition: entityControlPanelWidgetInterface.h:36
Redirect to radioMsgTypes.h.
DtAirSpeedType myAirSpeedType
Definition: entityControlPanelWidgetLogic.h:149
DtAirSpeedType
Air Speed Type PDU enums.
Definition: rwAirSpeedType.h:24
Base class to provide boost signal/slot management.
DtSimTask is an abstract base class from which real tasks can derive. It manages the read/write capab...
Definition: simTask.h:30
double myMaxClimb
Definition: entityControlPanelWidgetLogic.h:123
DtString myPlatformType
Definition: entityControlPanelWidgetLogic.h:139
bool mySelectionIsValid
selection is valid if all selected entity types are of the same movemnt parameters type and all alt a...
Definition: entityControlPanelWidgetLogic.h:133
Contains makVrv::DtUniqueID type.
bool mySelectionIsSupported
selection is supported if all selected entity types are supported if not, the panel will still displa...
Definition: entityControlPanelWidgetLogic.h:137
The DtDe is the core component of any VR-Vantage application. It owns a DtRenderer, DtDeCommunicator, as well as a DtDisplay and other things.
Definition: DtDe.h:70
double myMaxSpeedRange
Definition: entityControlPanelWidgetLogic.h:154
Contains makVrv::DtInputDriverSignaler class.
double myMinSpeedRange
Keep track of current speed range in ms to be used when changing air speed type.
Definition: entityControlPanelWidgetLogic.h:153
std::set< makVrv::DtUniqueID > mySelected
Definition: entityControlPanelWidgetLogic.h:113
makVrf::DtEntityMapperKey mySelectedMapperKey
Definition: entityControlPanelWidgetLogic.h:120

Document ID: Generated on Sun Dec 4 20:22:03 EST 2022 from SVN revision 249613
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)