jizhi
bobpan 5 years ago
parent 9a3988ea8d
commit 5fca70e291

@ -17,7 +17,7 @@ typedef std::function<QVariant(int)> FuncCallBack_VarInt;
typedef std::function<void(const QVariantMap&)> FuncCallBack_VarMap;
typedef std::function<void(const QString&, const QVariantMap&)> FuncCallBack_StrMap;
typedef std::function<void(const QString&, QImage)> FuncCallBack_StrImg;
typedef std::function<void(const QString&, emTpCameraStatus, bool)> FuncCallBack_StrInt;
//interface for gui
class ICoreCtrl
{
@ -48,10 +48,10 @@ public:
virtual bool ISetWidth(const QString& strSerial, int& width) = 0;
virtual bool IGetHeight(const QString& strSerial, int& height) = 0;
virtual bool ISetHeight(const QString& strSerial, int& height) = 0;
virtual bool IGetGain(const QString& strSerial, int& height) = 0;
virtual bool ISetGain(const QString& strSerial, int& height) = 0;
virtual bool IGetExposureTime(const QString& strSerial, int& height)=0;
virtual bool ISetExposureTime(const QString& strSerial, int& height)=0;
virtual bool IGetGain(const QString& strSerial, int& gain) = 0;
virtual bool ISetGain(const QString& strSerial, int& gain) = 0;
virtual bool IGetExposureTime(const QString& strSerial, int& exposure)=0;
virtual bool ISetExposureTime(const QString& strSerial, int& exposure)=0;
virtual bool IGetPixelFormat(const QString& strSerial) { return false; };
virtual bool ISetPixelFormat(const QString& strSerial) { return false; };
virtual bool IGetAcquisitionMode(const QString& strSerial) { return false; };
@ -63,11 +63,10 @@ public:
virtual void loadConfig() = 0;
virtual void saveConfig() = 0;
virtual bool IRegisterGetVariant(FuncCallBack_VarInt callback) = 0; //向算法传递检测参数回调接口
virtual bool IRegisterImageCallBack(FuncCallBack_StrImg callback) = 0; //获取相机图像回调接口
virtual bool IRegisterResultCallBack(FuncCallBack_StrMap callback) = 0; //获取算法结果回调接口
virtual bool IRegisterResultCallBack(FuncCallBack_StrMap callback) = 0; //注册算法结果回调函数 可获取算法检测结果
virtual bool IRegisterCamEventCallBack(FuncCallBack_StrInt callback) = 0;//注册相机事件回调函数 可获取相机打开关闭等相关事件
public://private: //use private when the old main is discarded;
virtual int IInitCore(class IDetectorEngine* pDE = NULL) = 0;
virtual void IFreeCore() = 0;

@ -307,8 +307,7 @@ QMap<QString, cv::Mat> ModelManager::getAllImgsExcSelf(QString strName /*= QStri
if (lst.at(i) == strName) {
continue;
}
if (i == 35)
int a = 0;
TempImage *pImg = getTmpImage(lst.at(i));
if (pImg) {
const std::vector<cv::Mat> &imgVec = pImg->getImgVector(1);

Loading…
Cancel
Save