VR-Forces 5.0.3 Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
DtHatHotResponder.h
Go to the documentation of this file.
1 /*********************************************************************
2 ** Copyright (c) 2020 MaK Technologies, Inc.
3 ** All rights reserved.
4 *********************************************************************/
5 
9 
10 #pragma once
11 
12 #include <vrvCigi/vrvCigi.h>
13 #include <vrvCore/DtUniqueID.h>
15 
16 #include <map>
17 
18 #include <matrix/vlVector.h>
19 
20 #include <vrvUtil/signalslib.h>
21 
22 class CigiBaseHatHotReq;
23 class CigiHatHotReqV3_2;
24 class CigiHatHotReqV4;
25 
26 namespace makVrv
27 {
28  class DtCigiEntityVisualizer;
29  class DtCigiConnection;
30 
36  {
37  public:
40  {
41  Hat = 0,
42  Hot = 1,
43  Extended = 2
44  };
45 
58  {
59  unsigned short hatHotId;
65  unsigned int lastHostFrameNumber;
66  };
67 
71  {
72  unsigned short hatHotId;
73  bool valid;
75  unsigned int lastHostFrameNumber;
76  double hatValue;
77  double hotValue;
78  int materialCode; // This is a DtElementType
81  };
82 
84 
86  virtual ~DtHatHotResponder();
87 
89  virtual void processHatHotRequests();
90 
92  boost::signalslib::signal<void ( const DtHatHotRequestData& )> signal_hatHotRequested;
93 
94  protected:
97 
100  void processHatHotRequest( CigiBaseHatHotReq& hatHotReq);
101 
104  void processHatHotV3( CigiHatHotReqV3_2 &hatHotReq);
105 
108  void processHatHotV4( CigiHatHotReqV4 &hatHotReq);
109 
110 
113  virtual void sendHatHotRequest( DtHatHotRequestData& request );
114 
115  protected:
119  typedef std::map<int, DtHatHotRequestData> HatHotRequestMap;
122  };
123 
126  {
127  public:
130 
132  virtual ~DtHatHotResponderCreator();
133 
135  static DtHatHotResponderCreator& instance( DtDe& de );
136 
138  static DtHatHotResponderCreator& instance( DtCigiConnection& con );
139 
141  virtual DtHatHotResponderCreator* clone();
142 
144  static void copyInstance(DtCigiConnection& con, DtDe& de);
145 
147  virtual DtHatHotResponder* create( DtCigiConnection& connection ) const;
148  };
149 }
HatHotType
Enum for the HATHOT Response Type.
Definition: DtHatHotResponder.h:39
Virtual base class. Allows for RTTI and proper virtual destruction. Used by Creators, Factories, Providers, Assemblers and User Interfaces.
Definition: DtVirtualBaseClass.h:19
bool valid
Definition: DtHatHotResponder.h:73
A DtHatHotResponder receives HAT/HOT requests from CIGI and either initiates an immediate request or ...
Definition: DtHatHotResponder.h:35
std::map< int, DtHatHotRequestData > HatHotRequestMap
Int key here is mapped to the HATHOT ID from packet. Note this map is only used if the requests are c...
Definition: DtHatHotResponder.h:119
float normalAzimuth
Definition: DtHatHotResponder.h:79
double hotValue
Definition: DtHatHotResponder.h:77
HatHotType responseType
Definition: DtHatHotResponder.h:74
DtVector location
Definition: DtHatHotResponder.h:61
unsigned int lastHostFrameNumber
Definition: DtHatHotResponder.h:65
boost::signalslib::signal< void(const DtHatHotRequestData &)> signal_hatHotRequested
Signal caught by the intersection handler.
Definition: DtHatHotResponder.h:92
Struct for HatHotResponseData. Unused in this class, used by intersection handler and the networkIO...
Definition: DtHatHotResponder.h:70
Contains DLL export macros.
HatHotRequestMap myHatHotRequests
Definition: DtHatHotResponder.h:120
Contains makVrv::DtVirtualBaseClass class.
Struct storage for the HatHotRequest Data Passed to the DtCigiIntersectionHandler for processing...
Definition: DtHatHotResponder.h:57
double hatValue
Definition: DtHatHotResponder.h:76
DtUniqueID entityId
Definition: DtHatHotResponder.h:60
int numberOfFramesBeforeSending
Definition: DtHatHotResponder.h:62
This class is responsible for the actual processing of CIGI data. This holds the entity visualizer...
Definition: DtCigiConnection.h:57
unsigned short hatHotId
Definition: DtHatHotResponder.h:59
float normalElevation
Definition: DtHatHotResponder.h:80
int lastFrameSent
Definition: DtHatHotResponder.h:63
Creator class for the DtHatHotResponder.
Definition: DtHatHotResponder.h:125
Contains makVrv::DtUniqueID type.
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
DtCigiConnection & myConnection
Definition: DtHatHotResponder.h:121
#define DT_DLL_VRVCIGI
Definition: vrvCigi.h:19
unsigned int lastHostFrameNumber
Definition: DtHatHotResponder.h:75
unsigned short hatHotId
Definition: DtHatHotResponder.h:72
HatHotType requestType
Definition: DtHatHotResponder.h:64
int materialCode
Definition: DtHatHotResponder.h:78

Document ID: Generated on Thu Jun 1 17:58:13 EDT 2023 from SVN revision 255404
Copyright © 2005-2021 MAK Technologies. All Rights Reserved (www.mak.com)