You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

216 lines
6.0 KiB

​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
7 years ago
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. #ifndef __QT5_MAIN_WINDOW_HEADER__
  2. #define __QT5_MAIN_WINDOW_HEADER__
  3. #include <WinSock2.h>
  4. #include "../../components/base/basicSettingsProvider.h"
  5. #include "../../gui/guiClass.h"
  6. #include "../../data/media/video/videoAVLIBSource.h"
  7. #include "../../gui/controls/VideoWidget.h"
  8. #include "../../gui/controls/OpenGLWidget.h"
  9. #include "../../gui/controls/OGLRadarWidget.h"
  10. #include "../../gui/controls/RangeMapWidget.h"
  11. #include "../../gui/controls/RadarMapWidget.h"
  12. #include "../../gui/controls/VideoSourceChooser.h"
  13. #include "../../gui/controls/DeviceChooser.h"
  14. #include "../../gui/controls/TimeShowWidget.h"
  15. #include "../../gui/controls/EventViewWidget.h"
  16. #include "../../gui/controls/ReportsManagerWindow.h"
  17. #include "../../gui/controls/mapControl/QMapControl"
  18. #include "../../gui/controls/mapControl/openaerialmapadapter.h"
  19. #include "../../components/object/objectLGS.h"
  20. #include "../../components/object/objectEventReport.h"
  21. //#include "../../gui/controls/SettingsLGS.h"
  22. #include "../../hardware/stick/joystick.h"
  23. class mainWinow : public QMainWindow{
  24. private:
  25. config_setting_t *m_pSettings;
  26. /* Main Widget */
  27. QWidget *m_pMainWidget;
  28. /* Layouts */
  29. QMainWindowLayout *m_pMainLayout;
  30. QVBoxLayout *m_pVerticalLayout;
  31. QVBoxLayout *m_pVerticalMapLayout;
  32. QVBoxLayout *m_pVerticalSideLayout;
  33. QHBoxLayout *m_pHorizontalLayout;
  34. QHBoxLayout *m_pScrolbarLayout;
  35. QVBoxLayout *m_pVVVLayout;
  36. QVBoxLayout *m_pVCVLayout;
  37. QPushButton *m_pButtonCmdVideoRecord;
  38. QSpacerItem *m_pVSpacer1;
  39. QSpacerItem *m_pVSpacer2;
  40. QSpacerItem *m_pVSpacer3;
  41. joysticObject *m_pJoyStick;
  42. /* Widgets */
  43. QFrame *m_pTitleFrame;
  44. TimeShowWidget *m_pTitleWidget;
  45. QStatusBar *m_pStatusBar;
  46. QSpacerItem *verticalSpacer;
  47. QSpacerItem *verticalSideSpacer;
  48. QSpacerItem *horisontalSpacer;
  49. QSpacerItem *scrolbarSpacer;
  50. QPushButton *m_pButtonCmdClear;
  51. QPushButton *m_pButtonCmdReset;
  52. QPushButton *m_pButtonCmdSilence;
  53. QPushButton *m_pButtonCmdReport;
  54. QPushButton *m_pButtonCmdExit;
  55. QPushButton *m_pButtonCmdSettings;
  56. QScrollArea *m_pScrollArea;
  57. QScrollArea *m_pDevScrollArea;
  58. EventViewerList *m_pEventsList;
  59. //QWidget *m_pScrollAreaWidgetContents;
  60. DeviceChooser *m_pDevScrollAreaWidgetContents;
  61. VideoSourceChooser *m_pScrollAreaWidgetContents;
  62. QPushButton *m_pAddVideoSource;
  63. VideoWidget *m_pMainVideoWidget;
  64. //clientPort *m_pMasterSocket;
  65. //clientPort *m_pSlaveSocket;
  66. //objectLGS *m_pMasterDevice;
  67. //objectLGS *m_pSlaveDevice;
  68. guiReportsManagerWindow *m_pReportManager;
  69. objectEventReport *m_pReportCreator;
  70. //Control Panels
  71. QTabWidget *m_pTabWidget;
  72. QWidget *m_pPage1;
  73. QWidget *m_pPage2;
  74. QWidget *m_pPage3;
  75. QWidget *m_pPage4;
  76. QWidget *m_pPage5;
  77. QHBoxLayout *m_pPage1Layout;
  78. QHBoxLayout *m_pPage2Layout;
  79. QVBoxLayout *m_pPage3Layout;
  80. QVBoxLayout *m_pPage4Layout;
  81. QVBoxLayout *m_pPage5Layout;
  82. QPushButton *m_pButton1;
  83. QPushButton *m_pButton2;
  84. QPushButton *m_pButton3;
  85. QPushButton *m_pButton4;
  86. QPushButton *m_pButton5;//Add Mask
  87. QPushButton *m_pButton6;//Delete Mask
  88. QPushButton *m_pButton7;//Activate Masks
  89. QPushButton *m_pButton8;//Deactivate Masks
  90. QHBoxLayout *mpLayout;
  91. QSpacerItem *mpSpacer;
  92. QProgressBar *m_pProgressBar;
  93. QHBoxLayout *m_pHorizontalLayout1;
  94. QHBoxLayout *m_pHorizontalLayout2;
  95. QHBoxLayout *m_pHorizontalLayout3;
  96. QRadioButton *m_pRadioButton1;
  97. QRadioButton *m_pRadioButton2;
  98. QGroupBox *m_pRadioGroup;
  99. QGroupBox *m_pSampleGroup;
  100. QComboBox *m_pLRFCombo;
  101. QLabel *m_pStMiRalabel;
  102. QLabel *m_pStMaRalabel;
  103. QLabel *m_pStMiSalabel;
  104. QLabel *m_pStMaSalabel;
  105. QLabel *m_pStMiRaVal;
  106. QLabel *m_pStMaRaVal;
  107. QLabel *m_pStMiSaVal;
  108. QLabel *m_pStMaSaVal;
  109. QLabel *m_pOpLabel;
  110. bool m_bUserRecordsVideo;
  111. private slots:
  112. void handleSilencePress();
  113. void handleButtonPress();
  114. void handleButton2Press();
  115. void handleMaximumsPress();
  116. void handleMinimumsPress();
  117. void handleGenerateWS();
  118. void handleSave2DPicture( void );
  119. void handleSave3DPicture(void);
  120. void handleAddMask();
  121. void handleDeleteMask();
  122. void handleUpdateMask();
  123. void handleSetStatusMask();
  124. void handleVideoRecorder();
  125. void handleReports();
  126. /*Map*/
  127. MapControl *m_pMapControl;
  128. MapAdapter *m_pMapAdapter;
  129. /* OpenGL */
  130. RangeMapWidget *m_pRangeMap;
  131. RadarMapWidget *m_pRangeRadar;
  132. GLRadar *m_pGLRadar;
  133. QPixmap *notepixmap;
  134. Layer* sights;
  135. Layer* museum;
  136. Layer* pubs;
  137. Layer* notes;
  138. Layer* base;
  139. /*Map*/
  140. /*
  141. mediaBus *m_pVideoBus1;
  142. videoAVLIBSource *m_pVideoIpput1;
  143. VideoThumbWidget *m_pVideoWidget1;
  144. mediaBus *m_pVideoBus2;
  145. videoAVLIBSource *m_pVideoIpput2;
  146. VideoThumbWidget *m_pVideoWidget2;
  147. mediaBus *m_pVideoBus3;
  148. videoAVLIBSource *m_pVideoIpput3;
  149. VideoThumbWidget *m_pVideoWidget3;
  150. */
  151. //serialPort *mSerial;
  152. //protocolPTZ_VISCA *mCamera;
  153. public:
  154. // Method to fetch singleton instance.
  155. static mainWinow* getInstance();
  156. // Destructor
  157. virtual ~mainWinow();
  158. RangeMapWidget *getRangeMap( void ){
  159. return m_pRangeMap;
  160. };
  161. RadarMapWidget *getRadarMap( void ){
  162. return m_pRangeRadar;
  163. };
  164. GLRadar *getGLRadar( void ){
  165. return m_pGLRadar;
  166. };
  167. protected:
  168. mainWinow();
  169. void changeEvent(QEvent *event);
  170. private:
  171. // private static member referencing the single instance of the object
  172. // TODO: Replace basicLogCollection with the type of object you want to
  173. // return the single instance of
  174. static mainWinow* _instance;
  175. // Copy constructor
  176. // Declared but not defined to prevent auto-generated
  177. // copy constructor. Refer to "Effective C++" by Meyers
  178. mainWinow(const mainWinow& src);
  179. // Assignment operator
  180. // Declared but not defined to prevent auto-generated
  181. // assignment operator. Refer to "Effective C++" by Meyers
  182. mainWinow& operator=(const mainWinow& src);
  183. public slots:
  184. void callbackSettings(void);
  185. void callbackClear(void);
  186. };
  187. #endif