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.

59 lines
1.6 KiB

7 years ago
​
7 years ago
7 years ago
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. #ifndef __RADAR_MAP_WIDGET_HEADER__
  2. #define __RADAR_MAP_WIDGET_HEADER__
  3. #ifndef __linux__
  4. #include <WinSock2.h>
  5. #endif
  6. #include "../guiClass.h"
  7. #include "../../components/object/objectLGS.h"
  8. #include "../../components/base/basicMutex.h"
  9. #include "../../alg/lgs/mask.h"
  10. #include "targetDisplay.h"
  11. class RadarMapWidget : public QFrame, public targetDisplay {
  12. private:
  13. QWidget *m_pParent;
  14. QImage *m_pImage;
  15. QImage m_oImage;
  16. basicMutex m_mImageLock;
  17. QPixmap m_oPixmap;
  18. QLabel *m_pImageLabel;
  19. QTimer *m_pAniTimer;
  20. QLabel *m_pOpLabel;
  21. point2DWidget *m_pPoint;
  22. QTimer *m_pStatusTimer;
  23. /* Masking Objects */
  24. float m_dScaleFactor;
  25. float m_fMaxRange;
  26. uint8_t m_bCurrentMouseMode;
  27. vectorMasking m_vAllPoly;
  28. simplePolygone *m_pNewPoly;
  29. int m_nCursorX;
  30. int m_nCursorY;
  31. int m_nAltStep;
  32. int m_nSelectedAlt;
  33. bool m_bShowMinimums;
  34. protected slots:
  35. void handleGenerateWS();
  36. void handleSavePicture();
  37. bool eventFilter(QObject* /*obj*/, QEvent* evt );
  38. virtual void resizeEvent(QResizeEvent *event);
  39. void wheelEvent(QWheelEvent* event);
  40. //void mouseMoveEvent(QMouseEvent* event);
  41. //virtual void paintEvent(QPaintEvent*);
  42. void handleTimer(void);
  43. virtual void updateDisplay( void );
  44. virtual void updateBackStage(void);
  45. public:
  46. explicit RadarMapWidget( QWidget *parent );
  47. ~RadarMapWidget();
  48. void startGenerateWS( void );
  49. void setMinimums(void);
  50. void setMaximums(void);
  51. void savePicture(QString fname);
  52. void attachLGS(objectLGS *ptr);
  53. QSize sizeHint() const;
  54. };
  55. #endif