123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121 |
- #ifndef CHARTSANDCAMERASWND_H
- #define CHARTSANDCAMERASWND_H
- #include <QMainWindow>
- #include <QSlider>
- #include <QLineEdit>
- #include <QSettings>
- #include "chartline.h"
- #include "CameraMaterialGroupWnd/MaterialWindow/Wafer.h"
- #include "CameraMaterialGroupWnd/MaterialWindow/Waffle.h"
- #include "CameraMaterialGroupWnd/MaterialWindow/MaterialBox.h"
- #include "JOriginalMainWnd.h"
- namespace Ui {
- class ChartsAndCamerasWnd;
- }
- class ChartsAndCamerasWnd : public JOriginalMainWnd
- {
- Q_OBJECT
- public:
- explicit ChartsAndCamerasWnd(QWidget *parent = nullptr);
- ~ChartsAndCamerasWnd();
- void initFrom();
- void updateMaterialWidget( int materialWndType, int groupId);
- protected:
- void wheelEvent(QWheelEvent *event) override;
- void loadSettings();
- void checkSettings();
- void loadGroupSettings(int Id, int Index);
- void showEvent(QShowEvent *event) override;
- void hideEvent(QHideEvent *event) override;
- private:
- void InitMainCameraBind(CameraBind* pCameraBind) override;
- void UpdateCameraDisplay0(int iCameraId, JVision::ImageInfo imageData) override;
- void UpdateCameraDisplay1(int iCameraId, JVision::ImageInfo imageData) override;
- void UpdateCameraDisplay2(int iCameraId, JVision::ImageInfo imageData) override;
- void UpdateCameraDisplay3(int iCameraId, JVision::ImageInfo imageData) override;
- void UpdateCameraDisplay4(int iCameraId, JVision::ImageInfo imageData) override;
- public slots: // 确保这里声明了槽函数
- private slots:
-
- QPixmap getCurrentPixmap() const {
- return currentPixmap;
- }
- // 通用槽函数
- // void on_GreenDiamondcheckBox_clicked();
- // void on_YellowDiamondcheckBox_clicked();
- // void on_BlackDiamondcheckBox_clicked();
- // void on_BlueDiamondcheckBox_clicked();
- // void on_BlueHorizontalLinecheckBox_clicked();
- // void on_BlueVerticalBarcheckBox_clicked();
- // void on_GreenVerticalBarcheckBox_clicked();
- // void on_PurpleVerticalBarcheckBox_clicked();
- // void on_RedDiamondcheckBox_clicked();
- // void on_RedHorizontalLinecheckBox_clicked();
- // void on_WhiteVerticalBarcheckBox_clicked();
- private:
- Ui::ChartsAndCamerasWnd *ui;
- // // 三个 ChartLine 实例
- // ChartLine *chartLine;
- // ChartLine *chartLine1;
- // ChartLine *chartLine2;
- // ChartLine 实例
- ChartLine *chartLine;
- ChartLine *chartLine1;
- ChartLine *chartLine2;
- // 存储所有系列信息
- QMap<QString, DataSeries> m_seriesMap;
- // 初始化系列信息
- void initializeSeriesInfo();
- QPixmap currentPixmap;
- qreal scaleFactor;
- double previousScaleFactor;
- int lastGroupId = -1;
- int lastIndex = -1;
- Wafer *wafer; // 声明Wafer指针
- Waffle *waffle; // 声明Waffle指针
- MaterialBox *materialbox; // 声明materialbox指针
- bool isShow;
- QMap<int, Wafer*> waferMap;
- QMap<int, Waffle*> waffleMap;
- QMap<int, MaterialBox*> materialBoxMap;
- OperateMode currentMode = ModeImage;
- QGraphicsView *currentView = nullptr;
- QPoint mousePos;
- };
- #endif // CHARTSANDCAMERASWND_H
|