1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465 |
- #pragma once
- #include <QDialog>
- #include <QDebug>
- #include <QListView>
- #include <QMenu>
- #include "../toolinterface.h"
- #include "HalconCpp.h"
- using namespace HalconCpp;
- // 筛选参数
- typedef struct Screening
- {
- int nIndex;
- QString strName;
- int nMin;
- int nMax;
- Screening()
- {
- nIndex = 0;
- nMin = 0;
- nMax = 999999;
- }
- }SCREENING;
- namespace Ui {
- class BlobSelectShape;
- }
- class BlobSelectShape : public ToolInterface
- {
- Q_OBJECT
- public:
- explicit BlobSelectShape(QWidget *parent = 0, ToolDialogImpl* p = nullptr);
- ~BlobSelectShape();
- virtual bool Serialized(QDataStream& ar, bool bIsOut);
- virtual QString ShowParameter();
- virtual int Execute();
- void AddTool(QString strName, int nMin, int nMax);
- private slots:
- void ActionSlot();
- void on_comboBox_currentIndexChanged(int index);
- void on_tableWidget_cellChanged(int row, int column);
- void on_BTN_Del_clicked();
- void on_comboBox_index_currentIndexChanged(int index);
- private:
- Ui::BlobSelectShape *ui;
- QVector<Screening> m_AllScreening;// 所有的拆选参数
- QMap<QString, QString> m_NamesMap;
- HTuple m_Key;
- HTuple m_MinValue;
- HTuple m_MaxValue;
- };
|