1 、添加偏距参数设置(集智需求)

2、优化找圆算法部分,修改使用背景图找圆逻辑
3、算法参数新增到UI页面上设置
4、以上功能均测试过
jizhi
bob.pan 5 years ago
parent cb34186041
commit ace2bff209

@ -34,6 +34,8 @@ public:
bool useHeight;
bool useDiameter;
QStringList defectList;
double dRatioVal{0};
int ratioType{ 0 };
};
CAlgorithmFluorescence::CAlgorithmFluorescence(void)
@ -46,9 +48,142 @@ CAlgorithmFluorescence::~CAlgorithmFluorescence(void)
}
//cv::BackgroundSubtractorMOG CAlgorithmFluorescence::bgSubtractor(30, 5, 0.95, false);
//检测算法入口函数 由corctl框架回调
int CAlgorithmFluorescence::IImageAnalysis(class IImageObject* pImgObj, TP_ALGORITHM_OPTION* pOpt, class IDetectorEngine* pDE)
{
qDebug() << "start alg";
QMutexLocker locker(&mutex);
double dStart = cv::getTickCount();
Mat matSrc = getImage(pImgObj).clone();//获取相机原始图像
QVariantMap vMap = pImgObj->IVarFromUI().toMap();//获取由UI传递过来的算法参数
//解析出模板库指针 这里获取的是整个模块库
long long modelMapPtr = vMap.value("modelMap").toLongLong();
QMap<QString, IWheelModel*> *ptr = (QMap<QString, IWheelModel*>*)modelMapPtr;
//获取需要检测的列表 型号名
long long defectListPtr = vMap.value("defectList").toLongLong();
QStringList* strModelListptr = (QStringList*)defectListPtr;
QStringList strModelList;
if(strModelListptr)
strModelList = *(strModelListptr);
int IsCutedImg = vMap.value("IsCutImg", 0).toInt();//裁剪后的轮毂图 检测模式 小图
int th = vMap.value("thickness", -1).toInt();//轮毂厚度 轮毂高度数据
bool useThickness = vMap.value("useThickness", 0).toBool();//是否使用厚度检测判断 匹配时过滤不符合范围的模板
bool useDiameter = vMap.value("useDiameter", 0).toBool();//是否使用直径参数检测判断
double dD2H = vMap.value("d2h", -1).toDouble();
int nthreshold = vMap.value("Threshold", 15).toInt();//图像阈值参数 使用背景图抠图算法时使用
bool bUseBackground = vMap.value("useBackground",false).toBool();//true 使用背景图抠图 false 不使用背景
int ratioType = vMap.value("RatioType").toInt();//偏距检测模式 启用方式
double ratioVal = vMap.value("Ratio").toDouble();//偏距系数
bool bEqual = vMap.value("bEqual").toBool();//使用使用图像增强
int filterSize = vMap.value("filterSize").toInt();//过滤圆大小
if (nthreshold <= 0)
nthreshold = 15;
QVariantMap rltMap;//算法检测结果值 输出到UI用
rltMap.insert("ratioVal", ratioVal);
luffy_base::luffyCircle lCircle;
static bool bReload = false;//背景图加载判断
Mat matBack = getBackGroundImage(pImgObj, bReload);//获取背景图
Mat matMatch;//抠图后的图像 目标图像
if (IsCutedImg == 0) //使用的是原始图像 需要执行圆查找算法找出 轮毂
{
//原始图像的size和背景图size不匹配 直接返回错误提示
if (bUseBackground == true && (matSrc.size().height != matBack.size().height || matSrc.size().width != matBack.size().width))
{
rltMap.insert("error", 0);
pImgObj->IVariantMapToUI(rltMap);
bReload = true;
return 0;
}
else{
bReload = false;
}
if (bUseBackground == true)//使用背景图 做减法找圆
{
matMatch = ImageProcess::findCircleByBackground(matSrc, matBack, &lCircle);
}
else {
//不需要 背景图找圆算法
Point2f centerPoint;
double radius = 0;
matMatch = ImageProcess::findCircle(matSrc, centerPoint, radius, bEqual,filterSize);
lCircle.ptCenter = centerPoint;
lCircle.fRadius = radius;
}
if (matMatch.cols >= 900 || matMatch.rows >= 900)//控制检测图像大小不能超过这个范围
{
cv::resize(matMatch, matMatch, cv::Size(matMatch.cols / 2, matMatch.rows / 2));
lCircle.fRadius = lCircle.fRadius / 2;
}
}
else{
matMatch = matSrc;
}
Result2Ui *pResult = new Result2Ui;
pResult->m_pixSrc = QtCVUtils::cvMatToQPixmap(matSrc);//!>原图像发送值UI 用于保存备份和调试
if (matMatch.empty())//抠图为空,表示抠图失败,直接返回错误
{
rltMap.insert("noCircle", 0);
long long varRlt = (long long)pResult;
rltMap.insert("result", varRlt);
pImgObj->IVariantMapToUI(rltMap);
return 0;
}
QString CAlgorithmFluorescence::bestMatch(const QMap<QString, IWheelModel*>* modelMap, CLocalWheel*pLocal, double* pMinDis /*= NULL*/, int minDisNum /*= -1*/) const
double dDiameter = dD2H * lCircle.fRadius * 2;//计算轮毂直径
//打包相关数据
CLocalWheel wheelLocal;
wheelLocal.defectList = strModelList;
wheelLocal.img = matMatch.clone();
wheelLocal.height = th;
wheelLocal.diameter = dDiameter;
wheelLocal.useHeight = useThickness;
wheelLocal.useDiameter = useDiameter;
wheelLocal.ratioType = ratioType;
wheelLocal.dRatioVal = ratioVal;
//开始匹配
if (!matMatch.empty() && ptr && ptr->size() > 0) {
vector<double> minDisVec(ptr->size());//初始化模板匹配分数值
QString str = bestMatch(ptr, &wheelLocal, &(minDisVec[0]), minDisVec.size());
pResult->m_strModel = str;
pResult->m_dMinDis = minDisVec[0];
if (ptr->contains(str) && ptr->value(str)->getImageComModel()) {
ICompareModel *pModel = ptr->value(str)->getImageComModel();
double d = pModel->getDisThre();
double dValue = (d - minDisVec[0]) / d * 0.4 + 0.6;
pResult->m_dScore = dValue;
}
}
qDebug() << "pull result";
QImage img = QtCVUtils::cvMatToQImage(matMatch);
pResult->m_pixResult = QtCVUtils::cvMatToQPixmap(matMatch);// .scaled(125, 125);
pResult->m_dDiameter = dDiameter;
pResult->m_dThickness = th;
//!>传递检测结果到UI
//pImgObj->IDrawImage(img.scaled(300, 300));//!>显示结果图片到UI的第二个窗口上
double dTime = (cv::getTickCount() - dStart) / cv::getTickFrequency();
pResult->m_dRunTime = dTime;
long long varRlt = (long long)pResult;
rltMap.insert("result", varRlt);
pImgObj->IVariantMapToUI(rltMap);
qDebug() << "finish alg";
return 1;
}
//模板匹配流程
QString CAlgorithmFluorescence::bestMatch(const QMap<QString, IWheelModel*>* modelMap, CLocalWheel* pLocal, double* pMinDis /*= NULL*/, int minDisNum /*= -1*/) const
{
double minDis = DBL_MAX;
QString bestName;
@ -68,13 +203,13 @@ QString CAlgorithmFluorescence::bestMatch(const QMap<QString, IWheelModel*>* mod
if (!modelMap->contains(strModelName))
continue;
QMap<QString,IWheelModel*>::const_iterator itsModel = modelMap->find(strModelName);
QMap<QString, IWheelModel*>::const_iterator itsModel = modelMap->find(strModelName);
disVec[nIndex] = DBL_MAX;
IWheelModel *pWheel = itsModel.value();
if (!pWheel)
break;
if (pLocal->useDiameter) {
if (abs(pLocal->diameter-pWheel->getDiameter()) >= 15) {
if (abs(pLocal->diameter - pWheel->getDiameter()) >= 15) {
nIndex++;
continue;
}
@ -85,7 +220,23 @@ QString CAlgorithmFluorescence::bestMatch(const QMap<QString, IWheelModel*>* mod
continue;
}
}
QString name = strModelName;// i.key();
if (pLocal->ratioType == 1) {//开启使用偏距过滤检测模板的功能
//必须三个数值不为0才进行 否则可能导致不明问题
double curRatioVal = pLocal->dRatioVal;
double minRatio = pWheel->getMinRotia();
double maxRatio = pWheel->getMaxRotia();
if (curRatioVal > 0 && minRatio > 0 && maxRatio > 0)
{
if (curRatioVal < minRatio || curRatioVal > maxRatio)
{
nIndex++;
continue;
}
}
}
QString name = strModelName;
ICompareModel* pModel = pWheel->getImageComModel();
if (pModel->getBaseImg().data == NULL)
@ -96,7 +247,7 @@ QString CAlgorithmFluorescence::bestMatch(const QMap<QString, IWheelModel*>* mod
pModel->setIsEnableCache(false);
double dis = pModel->compare(pLocal->img, NULL, true, 1);
double dis = pModel->compare(pLocal->img, NULL, true, 1);
double disThre = pModel->getDisThre();
double innerCircleNum = pModel->getInnerCircleNum();
if (dis < disThre)
@ -201,187 +352,9 @@ QString CAlgorithmFluorescence::bestMatch(const QMap<QString, IWheelModel*>* mod
}
}
//if (similarNum == 1)
//{
// double dis = std::fabs(innerCircleNumSum - simularModelMap.begin().value());
// if (dis > INSIDE_NUM_DIS_THRE)
// {
// bestName = QString();
// }
//}
//if (similarNum > 1)
//{
// auto iterEnd = simularModelMap.constEnd();
// double disMin = DBL_MAX;
// for (auto iter = simularModelMap.constBegin(); iter != iterEnd; ++iter)
// {
// double dis = std::fabs(innerCircleNumSum - iter.value());
// if (dis < disMin)
// {
// disMin = dis;
// bestName = iter.key();
// }
// }
//}
//auto iterEnd = simularModelMap.constEnd();
//bool bestMatchFlag = false;
//for (auto iter = simularModelMap.constBegin(); iter != iterEnd; ++iter)
//{
// double dis = std::fabs(innerCircleNumSum - iter.value());
// if (dis < INSIDE_NUM_DIS_THRE)
// {
// bestName = iter.key();
// bestMatchFlag = true;
// break;
// }
//}
//if (!bestMatchFlag)
//{
// bestName = QString();
//}
return bestName;
}
int CAlgorithmFluorescence::IImageAnalysis(class IImageObject* pImgObj, TP_ALGORITHM_OPTION* pOpt, class IDetectorEngine* pDE)
{
QMutexLocker locker(&mutex);
qDebug() << "start alg";
double dStart = cv::getTickCount();
Mat matSrc = getImage(pImgObj).clone();
QVariantMap vMap = pImgObj->IVarFromUI().toMap();
long long modelMapPtr = vMap.value("modelMap").toLongLong();
QMap<QString, IWheelModel*> *ptr = (QMap<QString, IWheelModel*>*)modelMapPtr;
long long defectListPtr = vMap.value("defectList").toLongLong();
QStringList* strModelListptr = (QStringList*)defectListPtr;
QStringList strModelList;
if(strModelListptr)
strModelList = *(strModelListptr);
int th = vMap.value("thickness", -1).toInt();
bool useThickness = vMap.value("useThickness", 0).toBool();
bool useDiameter = vMap.value("useDiameter", 0).toBool();
double dD2H = vMap.value("d2h", -1).toDouble();
int nthreshold = vMap.value("Threshold", 15).toInt();
bool bUseBackground = vMap.value("useBackground",false).toBool();//true 使用背景图抠图 false 不使用背景
if (nthreshold <= 0)
nthreshold = 15;
int IsCutedImg = vMap.value("IsCutImg", 0).toInt();//裁剪后的轮毂图
QVariantMap rltMap;
luffy_base::luffyCircle lCircle;
static bool bReload = false;
Mat matBack = getBackGroundImage(pImgObj, bReload);//获取背景图
Mat matMatch;//装载抠图后的图像
if (IsCutedImg == 0){
if (bUseBackground == true && (matSrc.size().height != matBack.size().height || matSrc.size().width != matBack.size().width))
{
rltMap.insert("error", 0);
pImgObj->IVariantMapToUI(rltMap);
bReload = true;
return 0;
}
else{
bReload = false;
}
//imageSegementation(matSrc);
//matMatch = ImageProcess::findCircleObject(matSrc, matBack, bUseBackground, nthreshold/*15*/, &lCircle/* NULL*/);
Point2f centerPoint;
double radius = 0;
matMatch = ImageProcess::findCircle(matSrc, centerPoint, radius, bUseBackground);
lCircle.ptCenter = centerPoint;
lCircle.fRadius = radius;
if (matMatch.cols >= 900 || matMatch.rows >= 900)
{
cv::resize(matMatch, matMatch, cv::Size(matMatch.cols / 2, matMatch.rows / 2));
lCircle.fRadius = lCircle.fRadius / 2;
}
}
else{
matMatch = matSrc;
}
Result2Ui *pResult = new Result2Ui;
pResult->m_pixSrc = QtCVUtils::cvMatToQPixmap(matSrc);//!>原图像发送值UI 用于保存备份和调试
if (matMatch.empty())
{
rltMap.insert("noCircle", 0);
long long varRlt = (long long)pResult;
rltMap.insert("result", varRlt);
pImgObj->IVariantMapToUI(rltMap);
return 0;
}
double dDiameter = dD2H * lCircle.fRadius * 2;
CLocalWheel wheelLocal;
wheelLocal.defectList = strModelList;
wheelLocal.img = matMatch.clone();
wheelLocal.height = th;
wheelLocal.diameter = dDiameter;
wheelLocal.useHeight = useThickness;
wheelLocal.useDiameter = useDiameter;
if (!matMatch.empty() && ptr && ptr->size() > 0) {
vector<double> minDisVec(ptr->size());
qDebug() << "start bestMatch";
QString str = bestMatch(ptr, &wheelLocal, &(minDisVec[0]), minDisVec.size());
qDebug() << "end bestMatch";
pResult->m_strModel = str;
pResult->m_dMinDis = minDisVec[0];
if (ptr->contains(str) && ptr->value(str)->getImageComModel()) {
ICompareModel *pModel = ptr->value(str)->getImageComModel();
double d = pModel->getDisThre();
double dValue = (d - minDisVec[0]) / d * 0.4 + 0.6;
pResult->m_dScore = dValue;
}
}
else if (matMatch.empty())
{
}
qDebug() << "pull result";
QImage img = QtCVUtils::cvMatToQImage(matMatch);
pResult->m_pixResult = QtCVUtils::cvMatToQPixmap(matMatch);// .scaled(125, 125);
pResult->m_dDiameter = dDiameter;
pResult->m_dThickness = th;
//!>传递检测结果到UI
//pImgObj->IDrawImage(img.scaled(300, 300));//!>显示结果图片到UI的第二个窗口上
double dTime = (cv::getTickCount() - dStart) / cv::getTickFrequency();
pResult->m_dRunTime = dTime;
long long varRlt = (long long)pResult;
rltMap.insert("result", varRlt);
pImgObj->IVariantMapToUI(rltMap);
qDebug() << "finish alg";
return 1;
}
QStringList *CAlgorithmFluorescence::getDefectListPtr(class IImageObject *pImgObj)
{
return nullptr;
// IAlgorithmShared *pShare = pImgObj->IGetShared();
// int nMap = pShare->IGetInt("defectList");
// return (QStringList*)nMap;
}
QMap<QString, IWheelModel*> *CAlgorithmFluorescence::getWheelMapPtr(class IImageObject *pImgObj)
{
// IAlgorithmShared *pShare = pImgObj->IGetShared();
// if (!pShare)
// return nullptr;
// int nMap = pShare->IGetInt("modelMap");
// return (QMap<QString, IWheelModel*>*)nMap;
return nullptr;
}
cv::Mat CAlgorithmFluorescence::getImage(class IImageObject *pImgObj)
{
@ -409,13 +382,11 @@ cv::Mat CAlgorithmFluorescence::getBackGroundImage(class IImageObject *pObj, boo
{
static Mat matback;
if (matback.empty()) {
QString filepath = /*getPath(pObj) +*/ ".\\user\\background.png";
QString filepath = ".\\user\\background.png";
matback = cv::imread(string((const char *)filepath.toLocal8Bit()), 0);
//matback = cv::imread(filepath.toLatin1().data(), 0);
if (matback.empty()) {
QString filepath = getPath(pObj) + "\\user\\background_r.png";
matback = cv::imread(string((const char *)filepath.toLocal8Bit()), 0);
//matback = cv::imread(filepath.toLatin1().data(), 0);
cv::flip(matback, matback, 1);
}
}
@ -426,7 +397,6 @@ cv::Mat CAlgorithmFluorescence::getBackGroundImage(class IImageObject *pObj, boo
if (matback.empty()) {
QString filepath = getPath(pObj) + "\\user\\background_r.png";
matback = cv::imread(string((const char *)filepath.toLocal8Bit()), 0);
//matback = cv::imread(filepath.toLatin1().data(), 0);
cv::flip(matback, matback, 1);
}
}
@ -445,69 +415,3 @@ QString CAlgorithmFluorescence::getPath(class IImageObject *pObj)
}
return mlist.first();
}
//void CAlgorithmFluorescence::imageSegementation(const cv::Mat &srcImage)
//{
// Mat mask;
// //Mat sobelImg = srcImage.clone();
// //genSobelImage(sobelImg);
// //sobelImg.convertTo(sobelImg, CV_8UC1);
//
//
// Mat sobelX, sobelY;
// Sobel(srcImage, sobelX, CV_32FC1, 1, 0, 3, BORDER_REPLICATE);
// Sobel(srcImage, sobelY, CV_32FC1, 0, 1, 3, BORDER_REPLICATE);
// Mat img = sobelX.mul(sobelX) + sobelY.mul(sobelY);
// Mat tempImg;
// img.convertTo(tempImg, CV_32FC1);
// Mat tempImg0;
// sqrt(tempImg, tempImg0);
// img = tempImg0;
// img.convertTo(img, CV_8UC1);
// Mat blurImg;
// cv::medianBlur(img, blurImg, 11);
// bgSubtractor(img, mask, 0.001);
//
// /*cv::Mat element5(5, 5, CV_8U, cv::Scalar(1));
// cv::Mat closedMat;
// cv::morphologyEx(mask, closedMat, cv::MORPH_CLOSE, element5);*/
//
// //cv::floodFill();
// luffy_base::luffyCircle pCircle;
//
// vector<cv::Mat> mats= ImageProcess::findCircleObject(mask, srcImage, 15, &pCircle);
// if (mats.size() == 0)
// {
// return;
// }
// if (mats[0].size() != mats[1].size())
// {
// return;
// }
// Mat dilatedImgBin;
// Mat imgBinary = mats[0] > 0;
// dilate(imgBinary, dilatedImgBin, Mat::ones(5, 5, CV_32FC1));
// erode(dilatedImgBin, imgBinary, Mat::ones(5, 5, CV_32FC1));
// imgBinary = ~imgBinary;
// //Mat canvas(imgBinary.size(), imgBinary.type(), Scalar::all(0));
// vector<vector<Point>> cons;
// cv::findContours(imgBinary, cons, RETR_EXTERNAL, CHAIN_APPROX_NONE);
// for (const vector<Point> & pContour : cons)
// {
// const int& size = pContour.size();
// if (size < 200)
// {
// Mat(pContour).setTo(255);
// //continue;
// }
// //cv::fillPoly(canvas, vector<vector<Point>>(1, pContour), Scalar(255));
// }
// //Mat tarMat = (~canvas).mul(mats[1]) / 255;
// //openOper(imgBinary, Mat::ones(1, 13, CV_32FC1));
//
//
//
//
// return;
//
//}

@ -28,16 +28,13 @@ class CAlgorithmFluorescence : public IAlgorithm
public:
CAlgorithmFluorescence(void);
virtual ~CAlgorithmFluorescence(void);
//void imageSegementation(const cv::Mat &srcImage);
//static cv::BackgroundSubtractorMOG bgSubtractor;
private:
virtual int IImageAnalysis(class IImageObject* pImgObj, TP_ALGORITHM_OPTION* pOpt, class IDetectorEngine* pDE);
private:
QString bestMatch(const QMap<QString, IWheelModel*>* modelMap, CLocalWheel*pLocal, double* pMinDis /*= NULL*/, int minDisNum /*= -1*/) const;
QMap<QString, IWheelModel*> *getWheelMapPtr(class IImageObject *pObj);
QString getPath(class IImageObject *pObj);
cv::Mat getImage(class IImageObject *pObj);
cv::Mat getBackGroundImage(class IImageObject *pObj, bool bReLoad = false);
QStringList *getDefectListPtr(class IImageObject *pImgObj);
QMutex mutex;
};

@ -44,6 +44,7 @@ Mat findEdge2(const Mat &Src)
return ret;
}
#define REAIZE 2
//老算法 准确率低
cv::Mat ImageProcess::findCircleObject(const Mat &src, const Mat& backgroundImg, bool useBackgroundFlag, int nThres /*= 20*/, luffy_base::luffyCircle *pCircle /*= NULL*/)
{
#ifdef MOTO_DETECT//摩轮型号识别抠图算法
@ -53,7 +54,6 @@ cv::Mat ImageProcess::findCircleObject(const Mat &src, const Mat& backgroundImg,
cv::resize(src, detectImg, cv::Size(src.cols / REAIZE, src.rows / REAIZE));
int bBaseX = detectImg.cols;
int bBaseY = detectImg.rows;
//if (nThres<=1)
equalizeHist(detectImg, detectImg);
detectImg = _EnhanImg_sharpen(detectImg);
@ -654,7 +654,7 @@ Mat ImageProcess::DetectCircle(Mat img, Point2f& center, double& radius, bool bE
CircleDetector cd;
cd.setAlgoType(CircleDetector::PeakCircle);
cd.setEdgeWidth(3);
cd.setEdgeWidth(6);
cd.setPolarity(Polarity::White2Black);
cd.setFindBy(FindBy::Best);
double difRadiusMin = radius - 100;
@ -692,4 +692,50 @@ Mat ImageProcess::DetectCircle(Mat img, Point2f& center, double& radius, bool bE
center = cen;
radius = r;
return s;
}
//使用背景图做减法扣圆
cv::Mat ImageProcess::findCircleByBackground(const Mat &src, const Mat& backgroundImg, luffy_base::luffyCircle *pCircle /*= NULL*/)
{
if (src.empty() || backgroundImg.empty() || src.rows < 500) {
return Mat();
}
assert(backgroundImg.type() == CV_8UC1);
Mat imgTmp = src;
Mat foregroundImg = getForeImage(imgTmp, backgroundImg);
CircleDetector cd;
cd.setAlgoType(CircleDetector::PeakCircle);
cd.setEdgeWidth(6);
cd.setPolarity(Polarity::White2Black);
cd.setFindBy(FindBy::Best);
double difRadiusMin = 0;
double difRadiusMax = (foregroundImg.cols>foregroundImg.rows? foregroundImg.rows/2 : foregroundImg.cols/2)-50;
cd.setRadii(difRadiusMin, difRadiusMax);
cd.setACThres(3);
vector<float> allScores;
Vec3f bestCircle;
float bestScore = cd.detectBest(foregroundImg, Point2f(imgTmp.cols/2, imgTmp.rows/2), bestCircle, &allScores);
if (abs(bestScore) <= FLT_EPSILON || bestCircle == Vec3f::zeros()) {
return Mat();
}
Point2f cen(bestCircle[0], bestCircle[1]);
double r = bestCircle[2];
Rect rect;
rect.x = cen.x - r;
rect.y = cen.y - r;
if (rect.x < 0)
rect.x = 0;
if (rect.y < 0)
rect.y = 0;
rect.width = 2 * r;
rect.height = 2 * r;
Mat rltMat = src(rect);
if (pCircle)
{
pCircle->fRadius = r;
pCircle->ptCenter = cen;
}
return rltMat;
}

@ -23,10 +23,9 @@ public:
static cv::Mat findCircleObject(const Mat &src, const Mat& backgroundImg, bool useBackgroundFlag, int nThres = 20, luffy_base::luffyCircle *pCircle = NULL);
static cv::Mat getForeImage(const Mat & src, const Mat &backgroundImg);
static cv::Mat findCircle(const Mat &srcImg, Point2f& center, double &radius, bool bEqual, int filterSize=50);//找圆
static cv::Mat DetectCircle(Mat img, Point2f& center, double& radius, bool bEqual);//精细找圆
static cv::Mat findCircleByBackground(const Mat &src, const Mat& backgroundImg, luffy_base::luffyCircle *pCircle /*= NULL*/);
};
#endif

@ -5,6 +5,7 @@
class TempImage;
class ICompareModel;
//extern int nGlobalMinImgs = 10;
/*模板型号接口文件*/
class IWheelModel
{
public:
@ -28,7 +29,7 @@ public:
virtual QString getPicPath() const = 0;
virtual void setPicPath(QString str) = 0;
virtual ICompareModel *getImageComModel() const = 0;
virtual ICompareModel *getImageComModel() const = 0;//获取模板算法模型
virtual void setImageComModel(ICompareModel *) = 0;
virtual TempImage *getTempImage() const = 0;
virtual bool initTmpImage(const QString&) = 0;
@ -37,9 +38,11 @@ public:
virtual int getImageModel() const = 0;
virtual int getImgCount() const = 0;
virtual bool getAddTrainFlag()const = 0;
virtual void setTrainFlag(bool bFlag) = 0;
private:
virtual void setTrainFlag(bool bFlag) = 0;//是否训练
virtual double getMinRotia() const = 0;//获取最小系数
virtual double getMaxRotia() const = 0;//获取最大系数
virtual void setMinRotia(double val) = 0;//设置最小系数
virtual void setMaxRotia(double val) = 0;//设置最大系数
};
#endif

@ -1,4 +1,5 @@
#pragma once
#ifndef _COMCONFIG_H_
#define _COMCONFIG_H_
#include "QString"
class ComConfig
{
@ -17,3 +18,4 @@ private:
QString appPath;
};
#endif

@ -43,6 +43,9 @@ void DetectState::init(QString strPath)
if (!algObj.isEmpty())
{
m_AlgThres = algObj.value("Threshold").toInt(15);
m_RatioDetectType = algObj.value("RatioType").toInt(0);
m_bUseEqual = algObj.value("bEqual").toBool(false);//使用使用图像增强
m_filterSize = algObj.value("filterSize").toInt(50);//过滤圆大小
}
else {
m_AlgThres = 15;
@ -234,7 +237,12 @@ void DetectState::saveDeteImage()
autosystemobj.insert("showThressList", m_showThressList);
jsMyself.insert(WHEEL_SELFDEFINE_AUTOITEM, autosystemobj);
QJsonObject algObj;
algObj.insert("Threshold", m_AlgThres);
algObj.insert("RatioType", m_RatioDetectType);
algObj.insert("bEqual", m_bUseEqual);//使用使用图像增强
algObj.insert("filterSize", m_filterSize);//过滤圆大小
jsMyself.insert(WHEEL_SELFDEFINE_ALGPARA, algObj);
QZkJsonParser::WriteJsonObject(fileMyself, jsMyself);
}
@ -268,6 +276,9 @@ void DetectState::save()
QJsonObject algObj;
algObj.insert("Threshold", m_AlgThres);
algObj.insert("RatioType", m_RatioDetectType);
algObj.insert("bEqual",m_bUseEqual);//使用使用图像增强
algObj.insert("filterSize",m_filterSize);//过滤圆大小
jsMyself.insert(WHEEL_SELFDEFINE_ALGPARA, algObj);
QZkJsonParser::WriteJsonObject(fileMyself, jsMyself);
}

@ -23,7 +23,7 @@ public:
int totalUnDetectNum; //无匹配数量
int m_IsUseRaster;//是否使用光栅标志 0 表示不使用 1 表示使用 光栅485通信//
int m_SaveD2HCsv;//保存厚度数据信息
int m_IsUseChannel;
int m_IsUseChannel{0};
int m_StartAndDetect;
int m_CameraTrigeType;//0 表示使用相机内触发模式 1表示使用传感器触发相机模式
@ -78,6 +78,10 @@ public:
int m_UseCutImg;
int m_UseBackground{0};
bool bLockDetect{ false };
int m_RatioDetectType{ 0 };//偏距检测模式: 0 不启用, 1 检测使用偏距过滤 ,2 结果使用偏距过滤
bool m_bUseEqual{ false };//是否使用图像增强
int m_filterSize{ 50 };//过滤圆大小
};
#endif

@ -5,16 +5,16 @@
#include "WheelModel.h"
#include "modelmgrdb.h"
#define WHEEL_MODEL_FILE "\\user\\model.json"
#define WHEEL_MODEL_FILE "\\pattern\\model.json"
#define WHEEL_DB_FILE "\\pattern\\modelTemplate.db"
#pragma execution_character_set("utf-8")
ModelManager::ModelManager(QString strRoot)
: m_strRoot(strRoot)
{
m_pModelDB = new ModelMgrDB(strRoot + WHEEL_DB_FILE);
hubBase::mkdir(m_strRoot + "\\pattern\\");
hubBase::mkdir(m_strRoot + "\\pattern\\template\\");
hubBase::mkdir(m_strRoot + "\\pattern\\Models\\");
m_pModelDB = new ModelMgrDB(strRoot + WHEEL_DB_FILE);
}
ModelManager::~ModelManager()

@ -3,7 +3,6 @@
#include "qstring.h"
#include "opencv\cv.h"
#include "opencv\highgui.h"
//#include "ImageProcess.h"
#include "qfile.h"
#include "qiodevice.h"
#include "qstringlist.h"
@ -20,20 +19,11 @@ ModelTrain::~ModelTrain()
{
}
// cv::Mat ModelTrain::findCircleObject(QString strPath, int nThres /*= 20*/, luffy_base::luffyCircle *pCircle /*= NULL*/)
// {
// //cv::Mat src = cv::imread(strPath.toLatin1().data(), 0);
// cv::Mat src = cv::imread(std::string((const char*)strPath.toLocal8Bit()), 0);
// cv::Mat back = ModelTrain::getBackGoundImage();
// return ImageProcess::findCircleObject(src, back, nThres, pCircle);
// }
cv::Mat ModelTrain::getBackGoundImage()
{
static cv::Mat matback;
if (matback.empty()){
QString filepath = qApp->applicationDirPath() + "\\user\\background.png";
//matback = cv::imread(filepath.toLatin1().data(), 0);
matback = cv::imread(std::string((const char*)filepath.toLocal8Bit()), 0);
}
return matback;

@ -1,6 +1,5 @@
#pragma once
#include "cv.h"
//#include "Luffy.h"
#include "qstring.h"
class ModelTrain
{
@ -8,7 +7,6 @@ public:
ModelTrain();
~ModelTrain();
static cv::Mat getBackGoundImage();
//static cv::Mat findCircleObject(QString strPath, int nThres = 20, luffy_base::luffyCircle *pCircle = NULL);
bool caliDiameter2Thickness(float &a, float &b);
private:
};

@ -88,14 +88,6 @@ std::vector<TempImageInfo*> TempImage::getVectors()
void TempImage::remove(const QString& strKey)
{
// for (int i = 0; i < m_imgTemplateLib.size(); i++) {
// if (m_imgTemplateLib.at(i)->m_strFileName == strKey) {
// hubBase::removeFile(m_imgTemplateLib.at(i)->m_strAbsoluteFilePath);
// TempImageInfo * pTemp = m_imgTemplateLib.at(i);
// m_imgTemplateLib.erase(pTemp);
// break;
// }
// }
for (std::vector<TempImageInfo*>::iterator its = m_imgTemplateLib.begin(); its != m_imgTemplateLib.end(); ++its){
if ((*its)->m_strFileName == strKey){
TempImageInfo* pTemp = (*its);

@ -1,7 +1,9 @@
#include "WheelModel.h"
#include "TempImage.h"
#include "ImageCompareModel.h"
#include "qjsonobject.h"
#include <QJsonObject>
#include <QJsonDocument>
#pragma execution_character_set("utf-8")
enum TEM_MODEL{
emTypeModelSuccess = 0,
@ -88,6 +90,8 @@ void WheelModel::readJson(QJsonObject *pJson)
m_passageway = obj.value("channel").toInt();
bDetect = obj.value("detect").toBool();
m_bAddTrain = obj.value("addTrain").toBool(true);
m_minRotia = obj.value("minRotia").toDouble();//最小系数
m_maxRotia = obj.value("maxRotia").toDouble();//最大系数
}
}
@ -100,6 +104,8 @@ void WheelModel::saveJson(class QJsonObject *pJson)
obj.insert("channel", m_passageway);
obj.insert("detect", bDetect);
obj.insert("addTrain", m_bAddTrain);
obj.insert("minRotia", m_minRotia);//最小系数
obj.insert("maxRotia", m_maxRotia);//最大系数
pJson->insert(m_strModelID, obj);
}

@ -41,6 +41,11 @@ public:
virtual int getImgCount() const;
virtual bool getAddTrainFlag()const { return m_bAddTrain; }
virtual void setTrainFlag(bool bFlag) { m_bAddTrain = bFlag; }
virtual double getMinRotia() const { return m_minRotia; }
virtual double getMaxRotia() const { return m_maxRotia; }
virtual void setMinRotia(double val) { m_minRotia = val; }
virtual void setMaxRotia(double val) { m_maxRotia = val; }
public:
QString m_strModelID;
double m_dHeight; //mm 厚度
@ -55,6 +60,9 @@ public:
class ChannelInfo *m_pChannelInfo;
class TempImage *m_pTempImage;
class ICompareModel *m_pDetectModel;
double m_minRotia{ 0.0 };//最小系数
double m_maxRotia{ 0.0 };//最大系数
};
#endif

@ -358,7 +358,10 @@ Q_SLOT void CWheelNet::DataRecvByte(QByteArray m_data)
{
//PLC触发相机 主动上报
qWarning() << "recv a camera triger time:" << QDateTime::currentDateTime().toString("yyyy-MM-dd hh:mm:ss zzz") << ";";
emit sgCameraTrig(lstData.at(0));// 第几个 索引
int hData = lstData.at(1);
int lData = lstData.at(2);
double dRatio = hData + lData * 1.0 / 1000;
emit sgCameraTrig(lstData.at(0), dRatio);// 第几个 索引
}
break;
case emTypeClear:

@ -62,7 +62,7 @@ signals:
void sgDeteState(bool);//发送离线时的检测状态的应答
void sgChangeOnlineState(int);//强制改变离线、在线状态
void sgRecvDetectState(int nIndex, int value);//在线时接收检测状态
void sgCameraTrig(int);//PLC触发相机时主动上报
void sgCameraTrig(int,double);//PLC触发相机时主动上报
void sgShow2UI(QString str, bool bConnect);
void sgClientConnect(QString addr, bool bConnect);
void sgServerState(QString, int, bool);//用来传送server打开 关闭状态

@ -6,8 +6,8 @@
<rect>
<x>0</x>
<y>0</y>
<width>203</width>
<height>166</height>
<width>339</width>
<height>213</height>
</rect>
</property>
<property name="windowTitle">
@ -20,6 +20,11 @@
<layout class="QGridLayout" name="gridLayout_2">
<item row="5" column="1">
<widget class="QPushButton" name="m_OK">
<property name="font">
<font>
<pointsize>12</pointsize>
</font>
</property>
<property name="text">
<string>确定</string>
</property>
@ -40,13 +45,24 @@
</item>
<item row="5" column="2">
<widget class="QPushButton" name="m_Cancle">
<property name="font">
<font>
<pointsize>12</pointsize>
</font>
</property>
<property name="text">
<string>取消</string>
</property>
</widget>
</item>
<item row="2" column="0" rowspan="2" colspan="3">
<widget class="QTextEdit" name="textEdit_about"/>
<widget class="QTextEdit" name="textEdit_about">
<property name="font">
<font>
<pointsize>12</pointsize>
</font>
</property>
</widget>
</item>
<item row="1" column="0" colspan="3">
<widget class="QLabel" name="label_4">
@ -56,6 +72,11 @@
<height>40</height>
</size>
</property>
<property name="font">
<font>
<pointsize>12</pointsize>
</font>
</property>
<property name="text">
<string>备注信息:</string>
</property>
@ -65,6 +86,11 @@
</item>
<item row="0" column="0">
<widget class="QLabel" name="label">
<property name="font">
<font>
<pointsize>12</pointsize>
</font>
</property>
<property name="text">
<string>名称:</string>
</property>
@ -74,7 +100,13 @@
</widget>
</item>
<item row="0" column="1">
<widget class="QLineEdit" name="lineEdit_key"/>
<widget class="QLineEdit" name="lineEdit_key">
<property name="font">
<font>
<pointsize>12</pointsize>
</font>
</property>
</widget>
</item>
</layout>
</item>

@ -18,7 +18,7 @@
#include "qworkItemdlg.h"
#include <QMessageBox>
#pragma execution_character_set("utf-8")
/*工作任务表配置页面 用于选择当天需要检测的型号列表*/
QWorkMgrUI::QWorkMgrUI(QWorkMgrCtlr *pWork, IWheelCtrl *pCtrl)
: m_pCtrl(pCtrl), m_pWorkCtrl(pWork), ptrModel(NULL), tableModel(NULL)
{

@ -16,7 +16,7 @@
</font>
</property>
<property name="windowTitle">
<string>QWorkMgrUI</string>
<string>检测配置任务表</string>
</property>
<layout class="QGridLayout" name="gridLayout_3">
<property name="leftMargin">
@ -107,7 +107,7 @@
</property>
<property name="font">
<font>
<pointsize>11</pointsize>
<pointsize>12</pointsize>
</font>
</property>
</widget>
@ -118,7 +118,7 @@
<widget class="QPushButton" name="workmgr_Add">
<property name="font">
<font>
<pointsize>11</pointsize>
<pointsize>12</pointsize>
</font>
</property>
<property name="toolTip">
@ -133,7 +133,7 @@
<widget class="QPushButton" name="workmgr_Del">
<property name="font">
<font>
<pointsize>11</pointsize>
<pointsize>12</pointsize>
</font>
</property>
<property name="toolTip">
@ -148,7 +148,7 @@
<widget class="QPushButton" name="workmgr_Mod">
<property name="font">
<font>
<pointsize>11</pointsize>
<pointsize>12</pointsize>
</font>
</property>
<property name="toolTip">
@ -163,7 +163,7 @@
<widget class="QPushButton" name="work_Edit_pb">
<property name="font">
<font>
<pointsize>11</pointsize>
<pointsize>12</pointsize>
</font>
</property>
<property name="toolTip">
@ -198,7 +198,7 @@
<widget class="QLabel" name="label">
<property name="font">
<font>
<pointsize>11</pointsize>
<pointsize>12</pointsize>
</font>
</property>
<property name="text">
@ -211,6 +211,11 @@
<property name="enabled">
<bool>false</bool>
</property>
<property name="font">
<font>
<pointsize>12</pointsize>
</font>
</property>
</widget>
</item>
</layout>
@ -225,7 +230,7 @@
</property>
<property name="font">
<font>
<pointsize>11</pointsize>
<pointsize>12</pointsize>
</font>
</property>
</widget>
@ -234,7 +239,7 @@
<widget class="QLabel" name="work_Num_label">
<property name="font">
<font>
<pointsize>11</pointsize>
<pointsize>12</pointsize>
</font>
</property>
<property name="text">
@ -336,7 +341,7 @@
</font>
</property>
<property name="currentIndex">
<number>1</number>
<number>0</number>
</property>
<widget class="QWidget" name="tab">
<attribute name="title">
@ -353,7 +358,7 @@
</property>
<property name="font">
<font>
<pointsize>11</pointsize>
<pointsize>12</pointsize>
</font>
</property>
<property name="text">
@ -371,7 +376,7 @@
</property>
<property name="font">
<font>
<pointsize>11</pointsize>
<pointsize>12</pointsize>
</font>
</property>
<property name="text">
@ -389,7 +394,7 @@
</property>
<property name="font">
<font>
<pointsize>11</pointsize>
<pointsize>12</pointsize>
</font>
</property>
<property name="text">
@ -420,6 +425,11 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="font">
<font>
<pointsize>12</pointsize>
</font>
</property>
</widget>
</item>
<item row="0" column="0">
@ -443,7 +453,7 @@
<widget class="QListWidget" name="work_models_listWidget">
<property name="font">
<font>
<pointsize>11</pointsize>
<pointsize>12</pointsize>
</font>
</property>
</widget>
@ -452,7 +462,7 @@
<widget class="QLabel" name="work_num_Listlabel">
<property name="font">
<font>
<pointsize>11</pointsize>
<pointsize>12</pointsize>
</font>
</property>
<property name="text">

@ -0,0 +1,11 @@
#include "QAlgParamDlg.h"
QAlgParamDlg::QAlgParamDlg(QWidget *parent)
: QWidget(parent)
{
ui.setupUi(this);
}
QAlgParamDlg::~QAlgParamDlg()
{
}

@ -0,0 +1,19 @@
#ifndef _QALGPARAMDLG_H_
#define _QALGPARAMDLG_H_
#include <QWidget>
#include "ui_QAlgParamDlg.h"
class QAlgParamDlg : public QWidget
{
Q_OBJECT
public:
QAlgParamDlg(QWidget *parent = Q_NULLPTR);
~QAlgParamDlg();
private:
Ui::QAlgParamDlg ui;
};
#endif

@ -0,0 +1,59 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>QAlgParamDlg</class>
<widget class="QWidget" name="QAlgParamDlg">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>624</width>
<height>429</height>
</rect>
</property>
<property name="windowTitle">
<string>算法参数设置</string>
</property>
<widget class="QLabel" name="label">
<property name="geometry">
<rect>
<x>30</x>
<y>40</y>
<width>91</width>
<height>16</height>
</rect>
</property>
<property name="text">
<string>是否使用偏距</string>
</property>
</widget>
<widget class="QLabel" name="label_2">
<property name="geometry">
<rect>
<x>30</x>
<y>70</y>
<width>54</width>
<height>12</height>
</rect>
</property>
<property name="text">
<string>TextLabel</string>
</property>
</widget>
<widget class="QLabel" name="label_3">
<property name="geometry">
<rect>
<x>30</x>
<y>100</y>
<width>54</width>
<height>12</height>
</rect>
</property>
<property name="text">
<string>TextLabel</string>
</property>
</widget>
</widget>
<layoutdefault spacing="6" margin="11"/>
<resources/>
<connections/>
</ui>

@ -23,7 +23,7 @@
</sizepolicy>
</property>
<property name="styleSheet">
<string notr="true">background-color: rgb(130, 136, 255);</string>
<string notr="true">background-color: rgb(202, 202, 202);</string>
</property>
</widget>
</item>

@ -85,6 +85,9 @@ QModelMgrDlg::QModelMgrDlg(IWheelCtrl *ptr, QWidget *parent)
QRegExp regExpNum("((6553[0-5])|[655[0-2][0-9]|65[0-4][0-9]{2}|6[0-4][0-9]{3}|[1-5][0-9]{4}|[1-9][0-9]{3}|[1-9][0-9]{2}|[1-9][0-9]|[0-9])");
ui.ModelMgr_model_edit_height->setValidator(new QRegExpValidator(regExpNum, this));
ui.ModelMgr_model_edit_diameter->setValidator(new QRegExpValidator(regExpNum, this));
// QRegExp doubleRegExp("^\d+(\.\d+)?$");
// ui.lineEdit_minRatio->setValidator(new QRegExpValidator(doubleRegExp, this));
// ui.lineEdit_maxRatio->setValidator(new QRegExpValidator(doubleRegExp, this));
}
ui.m_pbDelAll->setVisible(false);
@ -198,6 +201,9 @@ Q_SLOT void QModelMgrDlg::onModifyModel()
}
pModel->setThickness(ui.ModelMgr_model_edit_height->text().toDouble());
pModel->setDiameter(ui.ModelMgr_model_edit_diameter->text().toDouble());
pModel->setMinRotia(ui.doubleSpinBox_min->value());
pModel->setMaxRotia(ui.doubleSpinBox_max->value());
bool trainFlag = ui.checkBox->isChecked();
pModel->setTrainFlag(trainFlag);
if (trainFlag == false)
@ -206,7 +212,6 @@ Q_SLOT void QModelMgrDlg::onModifyModel()
emit sgModifyModel(strModel);
}
double thisvalue = pModel->getImageComModel()->getDisThre();
double falsMinDis = pModel->getImageComModel()->getFalseSampleMinDis();
double disMax = pModel->getImageComModel()->getDisMax();
@ -515,6 +520,9 @@ Q_SLOT void QModelMgrDlg::onShowModelInfo(QString str)
ui.ModelMgr_model_edit->setText(m_pModelMgr->getModel(str)->getModelID());
ui.ModelMgr_model_edit_diameter->setText(QString::number(m_pModelMgr->getModel(str)->getDiameter()));
ui.ModelMgr_model_edit_height->setText(QString::number(m_pModelMgr->getModel(str)->getThickness()));
ui.doubleSpinBox_min->setValue(m_pModelMgr->getModel(str)->getMinRotia());
ui.doubleSpinBox_max->setValue(m_pModelMgr->getModel(str)->getMaxRotia());
ui.checkBox->setChecked(m_pModelMgr->getModel(str)->getAddTrainFlag());
double disThred = m_pModelMgr->getModel(str)->getImageComModel()->getDisThre();
@ -608,6 +616,8 @@ void QModelMgrDlg::onClearShow()
ui.ModelMgr_model_edit->setText("");
ui.ModelMgr_model_edit_diameter->setText("");
ui.ModelMgr_model_edit_height->setText("");
ui.doubleSpinBox_min->setValue(0);
ui.doubleSpinBox_max->setValue(0);
ui.checkBox->setChecked(false);
QPixmap pix(MODEL_UI_ICON_NONE);
ui.ModelMgr_modelpic_lable->setPixmap(pix.scaled(WS_PICSIZE, WS_PICSIZE));

@ -6,7 +6,7 @@
<rect>
<x>0</x>
<y>0</y>
<width>1031</width>
<width>993</width>
<height>657</height>
</rect>
</property>
@ -14,13 +14,6 @@
<string>QModelMgrDlg</string>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_3">
<item>
<widget class="QLabel" name="ModelMgr_WarningMsg">
<property name="text">
<string/>
</property>
</widget>
</item>
<item>
<widget class="QGroupBox" name="ModelMgr_groupBox_5">
<property name="font">
@ -328,48 +321,49 @@
<item>
<widget class="QLabel" name="label_4">
<property name="text">
<string>最小系数</string>
<string>最小偏距</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="lineEdit">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
<widget class="QDoubleSpinBox" name="doubleSpinBox_min">
<property name="buttonSymbols">
<enum>QAbstractSpinBox::NoButtons</enum>
</property>
<property name="maximumSize">
<size>
<width>100</width>
<height>16777215</height>
</size>
<property name="maximum">
<double>9999.989999999999782</double>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="label_5">
<property name="text">
<string>最大系数</string>
<string>最大偏距</string>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="lineEdit_2">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
<widget class="QDoubleSpinBox" name="doubleSpinBox_max">
<property name="buttonSymbols">
<enum>QAbstractSpinBox::NoButtons</enum>
</property>
<property name="maximumSize">
<property name="maximum">
<double>9999.989999999999782</double>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_4">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>100</width>
<height>16777215</height>
<width>40</width>
<height>20</height>
</size>
</property>
</widget>
</spacer>
</item>
</layout>
</item>

@ -64,7 +64,7 @@ QSystemSettingDlg::QSystemSettingDlg(QWidget *parent)
}
connect(ui.listWidget, SIGNAL(currentRowChanged(int)), this, SLOT(onSetCurrentIndex(int)));
}
ui.label->setVisible(false);
}
QSystemSettingDlg::~QSystemSettingDlg()
@ -237,6 +237,10 @@ void QSystemSettingDlg::addPicRoot(QTreeWidget *pTreewidget, QString strName)
picitems.append(new QTreeWidgetItem((QTreeWidget*)0, QStringList(tr("原图"))));
picitems.append(new QTreeWidgetItem((QTreeWidget*)0, QStringList(tr("原图"))));
picitems.append(new QTreeWidgetItem((QTreeWidget*)0, QStringList(tr("背景图"))));
// picitems.append(new QTreeWidgetItem((QTreeWidget*)0, QStringList(tr("阈值参数"))));
picitems.append(new QTreeWidgetItem((QTreeWidget*)0, QStringList(tr("图像增强"))));
picitems.append(new QTreeWidgetItem((QTreeWidget*)0, QStringList(tr("过滤半径"))));
picitems.append(new QTreeWidgetItem((QTreeWidget*)0, QStringList(tr("偏距系数"))));
picitems.append(new QTreeWidgetItem((QTreeWidget*)0, QStringList(tr("检测结果"))));
picitems.append(new QTreeWidgetItem((QTreeWidget*)0, QStringList(tr("图像保存路径"))));
picitems.append(new QTreeWidgetItem((QTreeWidget*)0, QStringList(tr("设置保存路径"))));
@ -268,11 +272,36 @@ void QSystemSettingDlg::addPicRoot(QTreeWidget *pTreewidget, QString strName)
m_saveImgSrc_bad->setChecked(DetectState::instance()->saveBad == (int)true);
QCheckBox *m_useBackground = new QCheckBox;
m_useBackground->setText(tr("使用背景图"));
m_useBackground->setText(tr("使用背景图抠图"));
m_useBackground->setObjectName("m_useBackground");
connect(m_useBackground, SIGNAL(stateChanged(int)), this, SLOT(onCheckstateChanged(int)));
m_useBackground->setChecked(DetectState::instance()->m_UseBackground == (int)true);
//算法参数
// m_Algthreshold = new QSpinBox();
// m_Algthreshold->setMinimum(0);
// m_Algthreshold->setMaximum(255);
// m_Algthreshold->setToolTip(tr("背景图抠图算法阈值参数"));
// m_Algthreshold->setValue(DetectState::instance()->m_AlgThres);
QCheckBox *m_bEqual = new QCheckBox;
m_bEqual->setText(tr("使用图像增强"));
m_bEqual->setObjectName("m_bEqual");
connect(m_bEqual, SIGNAL(stateChanged(int)), this, SLOT(onCheckstateChanged(int)));
m_bEqual->setChecked(DetectState::instance()->m_bUseEqual);
m_AlgFilterSize = new QSpinBox();
m_AlgFilterSize->setMinimum(1);
m_AlgFilterSize->setMaximum(9999);
m_AlgFilterSize->setToolTip(tr("过滤圆半径Size"));
m_AlgFilterSize->setValue(DetectState::instance()->m_filterSize);
QCheckBox *m_useRatio = new QCheckBox;
m_useRatio->setText(tr("使用偏距系数过滤模板"));
m_useRatio->setObjectName("m_useRatio");
connect(m_useRatio, SIGNAL(stateChanged(int)), this, SLOT(onCheckstateChanged(int)));
m_useRatio->setChecked(DetectState::instance()->m_RatioDetectType == 0 ? false : true);
//
QCheckBox *m_ResAll2A = new QCheckBox;
m_ResAll2A->setText(tr("轮毂全去A通道"));
m_ResAll2A->setObjectName("m_ResAll2A");
@ -303,17 +332,27 @@ void QSystemSettingDlg::addPicRoot(QTreeWidget *pTreewidget, QString strName)
pTreewidget->setItemWidget(picitems.at(3), 1, m_saveImgSrc_good);
pTreewidget->setItemWidget(picitems.at(4), 1, m_saveImgSrc_bad);
pTreewidget->setItemWidget(picitems.at(5), 1, m_useBackground);
pTreewidget->setItemWidget(picitems.at(6), 1, m_ResAll2A);
pTreewidget->setItemWidget(picitems.at(7), 1, m_pLbShowPath);
pTreewidget->setItemWidget(picitems.at(8), 1, pbSetSavePath);
pTreewidget->setItemWidget(picitems.at(9), 1, pbOpenImgPath);
pTreewidget->setItemWidget(picitems.at(10), 1, pSavePara);
// pTreewidget->setItemWidget(picitems.at(6), 1, m_Algthreshold);
pTreewidget->setItemWidget(picitems.at(6), 1, m_bEqual);
pTreewidget->setItemWidget(picitems.at(7), 1, m_AlgFilterSize);
pTreewidget->setItemWidget(picitems.at(8), 1, m_useRatio);
pTreewidget->setItemWidget(picitems.at(9), 1, m_ResAll2A);
pTreewidget->setItemWidget(picitems.at(10), 1, m_pLbShowPath);
pTreewidget->setItemWidget(picitems.at(11), 1, pbSetSavePath);
pTreewidget->setItemWidget(picitems.at(12), 1, pbOpenImgPath);
pTreewidget->setItemWidget(picitems.at(13), 1, pSavePara);
m_listObj.append(pChangeBGbp);
m_listObj.append(m_saveImgRes_bad);
m_listObj.append(m_saveImgRes_good);
m_listObj.append(m_saveImgSrc_bad);
m_listObj.append(m_useBackground);
// m_listObj.append(m_Algthreshold);
m_listObj.append(m_bEqual);
m_listObj.append(m_AlgFilterSize);
m_listObj.append(m_useRatio);
m_listObj.append(m_saveImgSrc_good);
m_listObj.append(m_ResAll2A);
m_listObj.append(m_pLbShowPath);
@ -332,6 +371,10 @@ void QSystemSettingDlg::addPicRoot(QTreeWidget *pTreewidget, QString strName)
picitems.at(8)->setSizeHint(1, QSize(100, 40));
picitems.at(9)->setSizeHint(1, QSize(100, 40));
picitems.at(10)->setSizeHint(1, QSize(100, 40));
picitems.at(11)->setSizeHint(1, QSize(100, 40));
picitems.at(12)->setSizeHint(1, QSize(100, 40));
picitems.at(13)->setSizeHint(1, QSize(100, 40));
// picitems.at(14)->setSizeHint(1, QSize(100, 40));
}
void QSystemSettingDlg::addPLCRoot(QTreeWidget *pTreewidget, QString strName)
@ -722,6 +765,12 @@ Q_SLOT void QSystemSettingDlg::onCheckstateChanged(int state)
else if (strObj == "m_useBackground") {
DetectState::instance()->m_UseBackground = int(state == 2);
}
else if (strObj == "m_bEqual") {
DetectState::instance()->m_bUseEqual = int(state == 2);
}
else if (strObj == "m_useRatio") {
DetectState::instance()->m_RatioDetectType = int(state == 2);
}
else if (strObj == "m_ResAll2A") {
DetectState::instance()->m_bObjAll2A = (state == 2 ? true : false);
}
@ -822,6 +871,19 @@ Q_SLOT void QSystemSettingDlg::onSavePLCPara()
// emit sgShowMsg(tr("数据已发送并保存"));
emit sgChangePLCParam();
}
showTipInfo();
}
void QSystemSettingDlg::showTipInfo()
{
if (m_timerID != 0)
{
killTimer(m_timerID);
m_timerID = 0;
}
m_timerID = startTimer(1000);
ui.label->setVisible(true);
emit sgParamChange();
}
void QSystemSettingDlg::readSettingFile()
@ -886,6 +948,16 @@ void QSystemSettingDlg::showEvent(QShowEvent *event)
}
void QSystemSettingDlg::timerEvent(QTimerEvent *event)
{
if (event->timerId() == m_timerID)
{
killTimer(m_timerID);
m_timerID = 0;
ui.label->setVisible(false);
}
}
Q_SLOT void QSystemSettingDlg::onTreeWidgetButton()
{
QString strObj = sender()->objectName();
@ -946,8 +1018,16 @@ Q_SLOT void QSystemSettingDlg::onTreeWidgetButton()
else
DetectState::instance()->m_CameraTrigeType = 0;
}
if (m_AlgFilterSize)
{
DetectState::instance()->m_filterSize = m_AlgFilterSize->value();
}
// if (m_Algthreshold)
// {
// DetectState::instance()->m_AlgThres = m_Algthreshold->value();
// }
DetectState::instance()->saveDeteImage();
//emit sgShowMsg(tr("保存完成"));
showTipInfo();
}
}

@ -20,6 +20,7 @@ public:
signals:
void sgChangeLanguage(QString strLanguage);
void sgChangePLCParam();
void sgParamChange();
private:
bool InitTreeWidget(QTreeWidget* pTreewidget);
void addComRoot(class QTreeWidget *pTreewidget, QString strName /*= QString()*/);
@ -44,9 +45,11 @@ private:
Q_SLOT void onCheckstateChanged(int state);
Q_SLOT void onSetCurrentIndex(int nIndex);
Q_SLOT void onSavePLCPara();
void showTipInfo();
protected:
virtual void showEvent(QShowEvent *event);
virtual void timerEvent(QTimerEvent *event);
private:
Ui::QSystemSettingUI ui;
QList<QObject*> m_listObj;
@ -74,6 +77,9 @@ private:
class QComboBox *m_PLCTrigerType{ nullptr };
class QSpinBox *m_PLC_RestartSeverCount{ nullptr };
// class QSpinBox *m_Algthreshold{ nullptr };
class QSpinBox *m_AlgFilterSize{ nullptr };
QStringList m_listwidgetItemStr;
QDiskCleanThread *pDiskCleanThread{ nullptr };
QSettings *m_setting{ nullptr };
@ -81,6 +87,9 @@ private:
bool nCheckThreadEable{ false };
class QLabel* m_pLbShowPath{ nullptr };
int m_timerID{ 0 };
};
#endif

@ -14,11 +14,11 @@
<string>系统设置</string>
</property>
<layout class="QGridLayout" name="gridLayout">
<item row="0" column="0">
<widget class="QListWidget" name="listWidget">
<item row="0" column="1">
<widget class="QTreeWidget" name="treeWidget">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
<horstretch>2</horstretch>
<horstretch>6</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
@ -27,13 +27,18 @@
<pointsize>12</pointsize>
</font>
</property>
<column>
<property name="text">
<string notr="true">1</string>
</property>
</column>
</widget>
</item>
<item row="0" column="1">
<widget class="QTreeWidget" name="treeWidget">
<item row="0" column="0">
<widget class="QListWidget" name="listWidget">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
<horstretch>6</horstretch>
<horstretch>2</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
@ -42,11 +47,13 @@
<pointsize>12</pointsize>
</font>
</property>
<column>
<property name="text">
<string notr="true">1</string>
</property>
</column>
</widget>
</item>
<item row="1" column="0" colspan="2">
<widget class="QLabel" name="label">
<property name="text">
<string>参数设置已生效!!!</string>
</property>
</widget>
</item>
</layout>

@ -22,9 +22,9 @@
#include "QZkJsonParser.h"
#include <QProcess>
#define VERSION_HUB "3.0.0.3"
#define VERSION_ALG "3.0.0.3"
#define UPDATE_TIME "2021-09-07"
#define VERSION_HUB "3.0.1.0"
#define VERSION_ALG "3.0.1.0"
#define UPDATE_TIME "2021-09-16"
#pragma execution_character_set("utf-8")
lpMainWin::lpMainWin(QWidget *parent)
@ -153,7 +153,7 @@ lpMainWin::lpMainWin(QWidget *parent)
m_CamSettingDlg->setCoreCtrlPtr(m_pCoreCtrl);
connect(m_pSystemSettingDlg, SIGNAL(sgChangeLanguage(QString)), this, SLOT(onLanguageChange(QString)));
connect(m_pSystemSettingDlg, SIGNAL(sgChangePLCParam()), this, SLOT(onChangePLCParam()));
connect(m_pSystemSettingDlg, SIGNAL(sgParamChange()), this, SLOT(onUpdateUI()));
m_pixMapList = new QPixmapListBar(ui.tp_main_tabWidget);
ui.tp_main_tabWidget->insertTab(0, m_pixMapList, tr("历史"));
ui.tp_main_tabWidget->setCurrentIndex(0);
@ -188,7 +188,7 @@ lpMainWin::lpMainWin(QWidget *parent)
connect(m_pNet, SIGNAL(sgRecvTrigPara()), this, SLOT(onRecvTrigPara()));
connect(m_pNet, SIGNAL(sgReadDetectState(int, QString)), this, SLOT(onReadDetectState(int, QString)));
connect(m_pNet, SIGNAL(sgReadDetectStateASK()), this, SLOT(onReadDetectStateASK()));
connect(m_pNet, SIGNAL(sgCameraTrig(int)), this, SLOT(onTrigRecv(int)));
connect(m_pNet, SIGNAL(sgCameraTrig(int,double)), this, SLOT(onTrigRecv(int,double)));
connect(m_pNet, SIGNAL(sgServerState(QString, int, bool)), this, SLOT(onServerState(QString, int, bool)));
connect(m_pNet, SIGNAL(sgShutDownComputer()), this, SLOT(onShutDownComputer()));
connect(m_pNet, SIGNAL(sgLibRev(bool)), SendModelLibTask, SLOT(WaitSingleIn(bool)));//xy lib
@ -259,8 +259,11 @@ lpMainWin::lpMainWin(QWidget *parent)
//m_PulseTimer.start(1000);
connect(this, SIGNAL(sgAutoExposure()), this, SLOT(onAutoExposure()));
connect(this, SIGNAL(sgShowRatioVal(double)), this, SLOT(onShowRatioVal(double)));
QString strPath = QApplication::applicationDirPath();
readExposureTimeConfig(strPath);
onUpdateUI();
}
lpMainWin::~lpMainWin()
@ -536,13 +539,15 @@ void lpMainWin::INewCameraImage(const QString& camKey, QImage img)
/*多线程发送算法结果*/
void lpMainWin::IVariantMapToUI(const QString& camKey, const QVariantMap& vMap)
{
m_glbalRatio = 0;
emit(sgShowImgState(tr("显示识别结果")));
Result2Ui *pResult = (Result2Ui*)vMap.value("result").toLongLong();
double vRatioVal = vMap.value("ratioVal").toDouble();
if (pResult == nullptr)
{
pResult = new Result2Ui();
}
emit sgShowRatioVal(vRatioVal);
// 当没抠出轮毂和NG时自动调整曝光时间重新拍照最多调整的次数为5次
if (m_autoExposureSwitch)
{
@ -563,7 +568,6 @@ void lpMainWin::IVariantMapToUI(const QString& camKey, const QVariantMap& vMap)
m_exposureTimeCount++;
if (m_exposureTimeCount >= m_exposureTimeArray.size())
{
// m_exposureTimeCount = 0;
emit(sgShowMsgdlg(tr("调整5次曝光时间后依然未能识别到轮毂")));
}
else
@ -594,7 +598,6 @@ void lpMainWin::IVariantMapToUI(const QString& camKey, const QVariantMap& vMap)
m_exposureTimeCount++;
if (m_exposureTimeCount >= m_exposureTimeArray.size())
{
// m_exposureTimeCount = 0;
emit(sgShowMsgdlg(tr("调整5次曝光时间后依然未能识别到轮毂")));
}
else
@ -626,18 +629,14 @@ void lpMainWin::IVariantMapToUI(const QString& camKey, const QVariantMap& vMap)
m_pCoreCtrl->ISetExposureTime(m_camKey, exp);
}
// m_pUi->processResult(pResult);
static int ErrorNum = 0;
if (m_pNet) {
if (pResult->m_strModel == "NG") {
//m_pNet->sendLight(0, 1, 1000, 10);//红灯
SendResultBee(LIGHT_REDBEE, 1);
SendResultBee(LIGHT_BEE, 1);
ErrorNum++;
}
else {
//m_pNet->sendLight(2, 1, 1000, 100);
SendResultBee(LIGHT_GREENBEE, 1);
ErrorNum = 0;
}
@ -646,8 +645,6 @@ void lpMainWin::IVariantMapToUI(const QString& camKey, const QVariantMap& vMap)
if (DetectState::instance()->IsDetect == false)
str += tr(",未开启检测功能造成的");
m_pCtrl->addLog(str, emTypeWaring);
//m_pNet->sendLight(0, 1, 2000, 100);
//m_pNet->sendLight(3, 1, 3000, 100);
SendResultBee(LIGHT_REDBEE, 3);
SendResultBee(LIGHT_BEE, 3);
}
@ -657,7 +654,7 @@ void lpMainWin::IVariantMapToUI(const QString& camKey, const QVariantMap& vMap)
SendResultStr2PLC(pResult);//发送检测结果字符到PLC
if (DetectState::instance()->m_SendChannelRes2COM)
SendResultChannelCOM(pResult);//发送检测结果通道到串口
if (DetectState::instance()->m_SendChannelRes2Net)
if (DetectState::instance()->m_SendChannelRes2Net>0 && DetectState::instance()->m_IsUseChannel>0)
SendResultChannel2PLC(pResult);//发送检测结果通道到PLC
m_pCtrl->saveResult(pResult);
@ -683,17 +680,21 @@ QVariant lpMainWin::IGetVariantById(int id)
if (DetectState::instance()->m_IsUseRaster == 0)
nThickness = m_nWfThress;
else
nThickness = m_pCtrl->getThickness();// m_houduVec.first();
//nThickness = 209;
nThickness = m_pCtrl->getThickness();
vMap.insert("thickness", QVariant(nThickness));
double dDiameter;// = (-794.25 * nThickness / 1000000.0 + 0.775960);
dDiameter = (DetectState::instance()->m_k * nThickness + DetectState::instance()->m_b);
vMap.insert("d2h", dDiameter);
vMap.insert("useThickness", DetectState::instance()->bUseThickness);
vMap.insert("useDiameter", DetectState::instance()->bUseDiameter);
vMap.insert("Threshold", DetectState::instance()->m_AlgThres);
vMap.insert("Threshold", DetectState::instance()->m_AlgThres);//算法图像阈值
vMap.insert("IsCutImg", DetectState::instance()->m_UseCutImg);
vMap.insert("useBackground", DetectState::instance()->m_UseBackground>0?true:false);//使用背景图
vMap.insert("Ratio", m_glbalRatio);//偏距系数
vMap.insert("RatioType", DetectState::instance()->m_RatioDetectType);//偏距检测模式 启用方式
vMap.insert("bEqual", DetectState::instance()->m_bUseEqual);//使用使用图像增强
vMap.insert("filterSize", DetectState::instance()->m_filterSize);//过滤圆大小
void* address = (void*)m_pCtrl->getAllModelMapPtr();
long long varadr = (long long)address;
@ -711,7 +712,6 @@ QVariant lpMainWin::IGetVariantById(int id)
return vMap;
}
Q_SLOT void lpMainWin::onLogInOut(QString strName, int level, int state)
{
lpGlobalData::instance()->m_curUser = strName;
@ -1226,8 +1226,9 @@ Q_SLOT void lpMainWin::onReadDetectStateASK()
}
}
Q_SLOT void lpMainWin::onTrigRecv(int m_value)
Q_SLOT void lpMainWin::onTrigRecv(int m_value,double dRatio)
{
m_glbalRatio = dRatio;
/*用于接收PLC触发相机的信号 自检是否收到图像 */
qDebug() << "recv a camera trig :" << QString::number(m_value);
qWarning() << "recv a Triger signal from PLC:" << "(" << QDateTime::currentDateTime().toString("yyyy-MM-dd hh:mm:ss zzz") << ")";
@ -1730,4 +1731,32 @@ Q_SLOT void lpMainWin::onAutoExposure()
}
onTriggerCam();
}
Q_SLOT void lpMainWin::onUpdateUI()
{
if (DetectState::instance()->m_IsUseChannel > 0)
{
ui.main_lb_res_Channle->setVisible(true);
ui.main_lb_res_Channle_Show->setVisible(true);
}
else {
ui.main_lb_res_Channle->setVisible(false);
ui.main_lb_res_Channle_Show->setVisible(false);
}
if (DetectState::instance()->m_RatioDetectType > 0)
{
ui.label_ratioTitle->setVisible(true);
ui.label_ratioValue->setVisible(true);
}
else {
ui.label_ratioTitle->setVisible(false);
ui.label_ratioValue->setVisible(false);
}
}
Q_SLOT void lpMainWin::onShowRatioVal(double val)
{
ui.label_ratioValue->setText(QString("%1").arg(val));
}

@ -62,11 +62,14 @@ signals:
void operate();
void sgNetData(int, QVariantMap);
void sgAutoExposure();
void sgShowRatioVal(double val);
private:
Q_SLOT void onLogInOut(QString strName, int level, int state);
Q_SLOT void onActionClicked();
Q_SLOT void onButtonClicked();
Q_SLOT void onAutoExposure();
Q_SLOT void onUpdateUI();//修改参数应用时刷新UI显示内容
Q_SLOT void onShowRatioVal(double val);
protected:
bool onInitCoreCtrl();
@ -93,7 +96,7 @@ protected:
Q_SLOT void onRecvTrigPara();
Q_SLOT void onReadDetectState(int nIndex, QString strModel);
Q_SLOT void onReadDetectStateASK();
Q_SLOT void onTrigRecv(int m_value);
Q_SLOT void onTrigRecv(int m_value, double dRatio);
Q_SLOT void onServerState(QString Addr, int port, bool m_state);
Q_SLOT void onShutDownComputer();
//timer slot
@ -199,7 +202,7 @@ private:
bool readExposureTimeConfig(const QString& strPath);
int getCurExposureTime();
double m_glbalRatio{ 0.0 };//偏距系数
};
#endif

@ -229,7 +229,7 @@
<property name="spacing">
<number>6</number>
</property>
<item row="1" column="0">
<item row="2" column="0">
<widget class="QPushButton" name="btn_start_detect">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
@ -288,152 +288,149 @@
<property name="bottomMargin">
<number>0</number>
</property>
<item row="16" column="0">
<widget class="QLabel" name="label_21">
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
<item row="14" column="1">
<widget class="QLabel" name="main_lb_res_ok_num">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="acceptDrops">
<bool>true</bool>
<property name="font">
<font>
<pointsize>12</pointsize>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
<property name="autoFillBackground">
<bool>true</bool>
<property name="styleSheet">
<string notr="true">background-color: rgb(170, 170, 127);</string>
</property>
<property name="text">
<string>0</string>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
</widget>
</item>
<item row="18" column="0">
<widget class="QLabel" name="main_lb_res_Channle">
<property name="font">
<font>
<pointsize>12</pointsize>
</font>
</property>
<property name="styleSheet">
<string notr="true">font: 75 12pt &quot;Consolas&quot;;</string>
<string notr="true"/>
</property>
<property name="frameShadow">
<enum>QFrame::Sunken</enum>
</property>
<property name="text">
<string>无匹配(个)</string>
<string>通道</string>
</property>
<property name="scaledContents">
<bool>true</bool>
</property>
</widget>
</item>
<item row="14" column="0">
<widget class="QLabel" name="label_20">
<item row="1" column="0" rowspan="5" colspan="3">
<widget class="QLabel" name="main_lb_res_model_pic">
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
<width>120</width>
<height>120</height>
</size>
</property>
<property name="acceptDrops">
<bool>true</bool>
</property>
<property name="autoFillBackground">
<bool>false</bool>
</property>
<property name="styleSheet">
<string notr="true">font: 75 12pt &quot;Consolas&quot;;</string>
<string notr="true">background-color: rgb(200, 200, 200);</string>
</property>
<property name="frameShape">
<enum>QFrame::NoFrame</enum>
<enum>QFrame::Box</enum>
</property>
<property name="text">
<string>已检测(个)</string>
</property>
<property name="textFormat">
<enum>Qt::AutoText</enum>
<string/>
</property>
<property name="scaledContents">
<bool>true</bool>
</property>
</widget>
</item>
<item row="8" column="0">
<widget class="QLabel" name="label_6">
<property name="maximumSize">
<size>
<width>82</width>
<height>16777215</height>
</size>
<bool>false</bool>
</property>
<property name="styleSheet">
<string notr="true">font: 75 12pt &quot;Consolas&quot;;</string>
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
<property name="text">
<string>匹配值</string>
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item row="10" column="0">
<widget class="QLabel" name="label_8">
<property name="minimumSize">
<size>
<width>70</width>
<height>19</height>
</size>
<item row="9" column="1">
<widget class="QLabel" name="main_lb_res_model_thickness">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="maximumSize">
<size>
<width>82</width>
<height>16777215</height>
</size>
<property name="font">
<font>
<pointsize>12</pointsize>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
<property name="styleSheet">
<string notr="true">font: 75 12pt &quot;Consolas&quot;;</string>
<string notr="true">background-color: rgb(170, 170, 127);</string>
</property>
<property name="text">
<string>直径(mm)</string>
<string>0</string>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
</widget>
</item>
<item row="13" column="0">
<widget class="QLabel" name="label_3">
<property name="minimumSize">
<size>
<width>82</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>82</width>
<height>16777215</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">font: 75 12pt &quot;Consolas&quot;;</string>
<item row="16" column="1">
<widget class="QLabel" name="main_lb_res_ng_num">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>时间(s)</string>
<property name="font">
<font>
<pointsize>12</pointsize>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
</widget>
</item>
<item row="17" column="0">
<widget class="QLabel" name="main_lb_res_Channle">
<property name="styleSheet">
<string notr="true">font: 75 12pt &quot;Consolas&quot;;</string>
</property>
<property name="frameShadow">
<enum>QFrame::Sunken</enum>
<string notr="true">background-color: rgb(170, 170, 127);</string>
</property>
<property name="text">
<string>通道</string>
<string>0</string>
</property>
<property name="scaledContents">
<bool>true</bool>
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
</widget>
</item>
<item row="13" column="1">
<widget class="QLabel" name="main_lb_res_model_time">
<item row="7" column="0" colspan="3">
<widget class="QLabel" name="main_lb_res_model_id">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>132</width>
<height>0</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">font: 75 12pt &quot;Consolas&quot;;
background-color: rgb(170, 170, 127);</string>
<string notr="true">font: 24pt &quot;Consolas&quot;;</string>
</property>
<property name="text">
<string>0</string>
@ -443,17 +440,24 @@ background-color: rgb(170, 170, 127);</string>
</property>
</widget>
</item>
<item row="16" column="1">
<widget class="QLabel" name="main_lb_res_ng_num">
<item row="10" column="1">
<widget class="QLabel" name="main_lb_res_model_diameter">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="font">
<font>
<pointsize>12</pointsize>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
<property name="styleSheet">
<string notr="true">font: 75 12pt &quot;Consolas&quot;;
background-color: rgb(170, 170, 127);</string>
<string notr="true">background-color: rgb(170, 170, 127);
</string>
</property>
<property name="text">
<string>0</string>
@ -463,39 +467,63 @@ background-color: rgb(170, 170, 127);</string>
</property>
</widget>
</item>
<item row="17" column="1">
<widget class="QLabel" name="main_lb_res_Channle_Show">
<item row="14" column="0">
<widget class="QLabel" name="label_20">
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="font">
<font>
<pointsize>12</pointsize>
</font>
</property>
<property name="acceptDrops">
<bool>true</bool>
</property>
<property name="autoFillBackground">
<bool>false</bool>
</property>
<property name="styleSheet">
<string notr="true">font: 75 12pt &quot;Consolas&quot;;
background-color: rgb(170, 170, 127);</string>
<string notr="true"/>
</property>
<property name="frameShape">
<enum>QFrame::NoFrame</enum>
</property>
<property name="text">
<string>---------</string>
<string>已检测(个)</string>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
<property name="textFormat">
<enum>Qt::AutoText</enum>
</property>
<property name="scaledContents">
<bool>true</bool>
</property>
</widget>
</item>
<item row="7" column="0" colspan="3">
<widget class="QLabel" name="main_lb_res_model_id">
<property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<item row="0" column="0" colspan="2">
<widget class="QLabel" name="main_label_state">
<property name="minimumSize">
<size>
<width>132</width>
<height>0</height>
<width>0</width>
<height>5</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">font: 24pt &quot;Consolas&quot;;</string>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>15</height>
</size>
</property>
<property name="font">
<font>
<pointsize>11</pointsize>
</font>
</property>
<property name="text">
<string>0</string>
<string>检测状态</string>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
@ -522,97 +550,118 @@ font: 75 24pt &quot;Consolas&quot;;</string>
</property>
</widget>
</item>
<item row="10" column="1">
<widget class="QLabel" name="main_lb_res_model_diameter">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
<item row="16" column="0">
<widget class="QLabel" name="label_21">
<property name="minimumSize">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
<property name="font">
<font>
<pointsize>12</pointsize>
</font>
</property>
<property name="acceptDrops">
<bool>true</bool>
</property>
<property name="autoFillBackground">
<bool>true</bool>
</property>
<property name="styleSheet">
<string notr="true">background-color: rgb(170, 170, 127);
font: 75 12pt &quot;Consolas&quot;;</string>
<string notr="true"/>
</property>
<property name="frameShadow">
<enum>QFrame::Sunken</enum>
</property>
<property name="text">
<string>0</string>
<string>无匹配(个)</string>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
<property name="scaledContents">
<bool>true</bool>
</property>
</widget>
</item>
<item row="1" column="0" rowspan="5" colspan="3">
<widget class="QLabel" name="main_lb_res_model_pic">
<property name="minimumSize">
<item row="8" column="0">
<widget class="QLabel" name="label_6">
<property name="maximumSize">
<size>
<width>120</width>
<height>120</height>
<width>82</width>
<height>16777215</height>
</size>
</property>
<property name="styleSheet">
<string notr="true">background-color: rgb(200, 200, 200);</string>
<property name="font">
<font>
<pointsize>12</pointsize>
</font>
</property>
<property name="frameShape">
<enum>QFrame::Box</enum>
<property name="styleSheet">
<string notr="true"/>
</property>
<property name="text">
<string/>
<string>匹配值</string>
</property>
<property name="scaledContents">
<bool>false</bool>
</widget>
</item>
<item row="10" column="0">
<widget class="QLabel" name="label_8">
<property name="minimumSize">
<size>
<width>70</width>
<height>19</height>
</size>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
<property name="maximumSize">
<size>
<width>82</width>
<height>16777215</height>
</size>
</property>
<property name="wordWrap">
<bool>false</bool>
<property name="font">
<font>
<pointsize>12</pointsize>
</font>
</property>
<property name="styleSheet">
<string notr="true"/>
</property>
<property name="text">
<string>直径(mm)</string>
</property>
</widget>
</item>
<item row="8" column="1">
<widget class="QLabel" name="main_lb_res_model_score">
<item row="18" column="1">
<widget class="QLabel" name="main_lb_res_Channle_Show">
<property name="font">
<font>
<family>Consolas</family>
<pointsize>12</pointsize>
<weight>9</weight>
<italic>false</italic>
<bold>false</bold>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
<property name="styleSheet">
<string notr="true">background-color: rgb(170, 170, 127);
font: 75 12pt &quot;Consolas&quot;;</string>
<string notr="true">background-color: rgb(170, 170, 127);</string>
</property>
<property name="text">
<string>0</string>
<string>---------</string>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
</widget>
</item>
<item row="14" column="1">
<widget class="QLabel" name="main_lb_res_ok_num">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<item row="8" column="1">
<widget class="QLabel" name="main_lb_res_model_score">
<property name="font">
<font>
<family>Consolas</family>
<pointsize>12</pointsize>
<weight>9</weight>
<italic>false</italic>
<bold>false</bold>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
<property name="styleSheet">
<string notr="true">font: 75 12pt &quot;Consolas&quot;;
background-color: rgb(170, 170, 127);</string>
<string notr="true">background-color: rgb(170, 170, 127);</string>
</property>
<property name="text">
<string>0</string>
@ -622,44 +671,50 @@ background-color: rgb(170, 170, 127);</string>
</property>
</widget>
</item>
<item row="0" column="0" colspan="2">
<widget class="QLabel" name="main_label_state">
<item row="13" column="0">
<widget class="QLabel" name="label_3">
<property name="minimumSize">
<size>
<width>0</width>
<height>5</height>
<width>82</width>
<height>0</height>
</size>
</property>
<property name="maximumSize">
<size>
<width>16777215</width>
<height>15</height>
<width>82</width>
<height>16777215</height>
</size>
</property>
<property name="font">
<font>
<pointsize>11</pointsize>
<pointsize>12</pointsize>
</font>
</property>
<property name="text">
<string>检测状态</string>
<property name="styleSheet">
<string notr="true"/>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
<property name="text">
<string>时间(s)</string>
</property>
</widget>
</item>
<item row="9" column="1">
<widget class="QLabel" name="main_lb_res_model_thickness">
<item row="13" column="1">
<widget class="QLabel" name="main_lb_res_model_time">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="font">
<font>
<pointsize>12</pointsize>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
<property name="styleSheet">
<string notr="true">font: 75 12pt &quot;Consolas&quot;;
background-color: rgb(170, 170, 127);</string>
<string notr="true">background-color: rgb(170, 170, 127);</string>
</property>
<property name="text">
<string>0</string>
@ -677,14 +732,51 @@ background-color: rgb(170, 170, 127);</string>
<height>16777215</height>
</size>
</property>
<property name="font">
<font>
<pointsize>12</pointsize>
</font>
</property>
<property name="styleSheet">
<string notr="true">font: 75 12pt &quot;Consolas&quot;;</string>
<string notr="true"/>
</property>
<property name="text">
<string>厚度(mm)</string>
</property>
</widget>
</item>
<item row="11" column="0">
<widget class="QLabel" name="label_ratioTitle">
<property name="font">
<font>
<pointsize>12</pointsize>
</font>
</property>
<property name="text">
<string>偏距</string>
</property>
</widget>
</item>
<item row="11" column="1">
<widget class="QLabel" name="label_ratioValue">
<property name="font">
<font>
<pointsize>12</pointsize>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
<property name="styleSheet">
<string notr="true">background-color: rgb(170, 170, 127);</string>
</property>
<property name="text">
<string>0</string>
</property>
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
</widget>
</item>
</layout>
</widget>
</item>
@ -762,7 +854,7 @@ background-color: rgb(170, 170, 127);</string>
</property>
<property name="font">
<font>
<pointsize>11</pointsize>
<pointsize>12</pointsize>
</font>
</property>
<property name="wheel_prop_tableview_header" stdset="0">

@ -33,7 +33,6 @@
<ClCompile Include="..\..\src\tpMain\ModelManager.cpp" />
<ClCompile Include="..\..\src\tpMain\modelmgrdb.cpp" />
<ClCompile Include="..\..\src\tpMain\ModelTableView.cpp" />
<ClCompile Include="..\..\src\tpMain\ModelTrain.cpp" />
<ClCompile Include="..\..\src\tpMain\NetProtocol.cpp" />
<ClCompile Include="..\..\src\tpMain\ProgressView.cpp" />
<ClCompile Include="..\..\src\tpMain\qaddchanneldlg.cpp" />
@ -111,6 +110,9 @@
<ClCompile Include="GeneratedFiles\Debug\moc_qaddtimedlg.cpp">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="GeneratedFiles\Debug\moc_QAlgParamDlg.cpp">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="GeneratedFiles\Debug\moc_QCamSettingDlg.cpp">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
</ClCompile>
@ -249,6 +251,9 @@
<ClCompile Include="GeneratedFiles\Release\moc_qaddtimedlg.cpp">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="GeneratedFiles\Release\moc_QAlgParamDlg.cpp">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
</ClCompile>
<ClCompile Include="GeneratedFiles\Release\moc_QCamSettingDlg.cpp">
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
</ClCompile>
@ -336,6 +341,7 @@
<ClCompile Include="lpGlobalData.cpp" />
<ClCompile Include="lpMain.cpp" />
<ClCompile Include="lpMainWin.cpp" />
<ClCompile Include="QAlgParamDlg.cpp" />
<ClCompile Include="QCamSettingDlg.cpp" />
<ClCompile Include="QChannelMgrDlg.cpp" />
<ClCompile Include="QDebugDlg.cpp" />
@ -345,6 +351,16 @@
<ClCompile Include="QTimeMgrDlg.cpp" />
</ItemGroup>
<ItemGroup>
<CustomBuild Include="QAlgParamDlg.h">
<AdditionalInputs Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(QTDIR)\bin\moc.exe;%(FullPath)</AdditionalInputs>
<Message Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Moc%27ing %(Identity)...</Message>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">.\GeneratedFiles\$(ConfigurationName)\moc_%(Filename).cpp</Outputs>
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">"$(QTDIR)\bin\moc.exe" "%(FullPath)" -o ".\GeneratedFiles\$(ConfigurationName)\moc_%(Filename).cpp" -DUNICODE -DWIN32 -DWIN64 -DQT_CORE_LIB -DTPMAIN_LIB -DTPMAIN_EXPORTS -DQT_GUI_LIB -DQT_WIDGETS_LIB -DQT_SQL_LIB -DQT_PRINTSUPPORT_LIB -DQT_NETWORK_LIB -DQT_SERIALPORT_LIB -D_WINDOWS -D%(PreprocessorDefinitions) "-I." "-I.\GeneratedFiles" "-I.\GeneratedFiles\$(ConfigurationName)" "-I$(QTDIR)\include" "-I$(QTDIR)\include\QtCore" "-I$(QTDIR)\include\QtGui" "-I$(QTDIR)\include\QtWidgets" "-I$(QTDIR)\include\ActiveQt" "-I$(QTDIR)\include\QtSerialPort" "-I$(QTDIR)\include\QtANGLE" "-I$(QTDIR)\include\QtPrintSupport" "-I$(QTDIR)\include\QtSql" "-I$(QTDIR)\include\QtNetwork" "-I.\..\..\src\algorithm" "-I.\..\..\src\tpMain" "-I.\..\..\src\tpMain\thread" "-I.\..\..\src\tpMain\splashScreen" "-I.\..\..\src\tpMain\LightBoxwidget" "-I.\..\..\src\tpMain\QDiskCleanThread" "-I.\..\..\src\tpMain\QPixmapListBar" "-I.\..\..\src\userCtrl" "-I.\..\..\src\NetWheel" "-I.\..\..\src\RasterSDG20" "-I.\..\..\src\ReportModel" "-I.\..\..\3part\libzkq\include" "-I.\..\..\3part\tadpole\include\tpBase" "-I.\..\..\3part\opencv3.4.1\include" "-I.\..\..\3part\opencv3.4.1\include\opencv" "-I.\..\..\3part\opencv3.4.1\include\opencv2" "-I.\..\..\3part\edcircle\include" "-I.\..\..\3part\lpCoreCtrl\include" "-I.\..\..\src\tpMain\algela" "-I.\..\..\src\ImageCompare" "-I.\..\..\src\interface"</Command>
<AdditionalInputs Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(QTDIR)\bin\moc.exe;%(FullPath)</AdditionalInputs>
<Message Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Moc%27ing %(Identity)...</Message>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|x64'">.\GeneratedFiles\$(ConfigurationName)\moc_%(Filename).cpp</Outputs>
<Command Condition="'$(Configuration)|$(Platform)'=='Release|x64'">"$(QTDIR)\bin\moc.exe" "%(FullPath)" -o ".\GeneratedFiles\$(ConfigurationName)\moc_%(Filename).cpp" -DUNICODE -DWIN32 -DWIN64 -DQT_NO_DEBUG -DNDEBUG -DQT_CORE_LIB -DTPMAIN_LIB -DTPMAIN_EXPORTS -DQT_GUI_LIB -DQT_WIDGETS_LIB -DQT_SQL_LIB -DQT_PRINTSUPPORT_LIB -DQT_NETWORK_LIB -DQT_SERIALPORT_LIB -D%(PreprocessorDefinitions) "-I." "-I.\GeneratedFiles" "-I.\GeneratedFiles\$(ConfigurationName)" "-I$(QTDIR)\include" "-I$(QTDIR)\include\QtCore" "-I$(QTDIR)\include\QtGui" "-I$(QTDIR)\include\QtWidgets" "-I$(QTDIR)\include\ActiveQt" "-I$(QTDIR)\include\QtSerialPort" "-I$(QTDIR)\include\QtANGLE" "-I$(QTDIR)\include\QtPrintSupport" "-I$(QTDIR)\include\QtSql" "-I$(QTDIR)\include\QtNetwork" "-I.\..\..\src\algorithm" "-I.\..\..\src\tpMain" "-I.\..\..\src\tpMain\thread" "-I.\..\..\src\tpMain\splashScreen" "-I.\..\..\src\tpMain\LightBoxwidget" "-I.\..\..\src\tpMain\QDiskCleanThread" "-I.\..\..\src\tpMain\QPixmapListBar" "-I.\..\..\src\userCtrl" "-I.\..\..\src\NetWheel" "-I.\..\..\src\RasterSDG20" "-I.\..\..\src\ReportModel" "-I.\..\..\3part\libzkq\include" "-I.\..\..\3part\tadpole\include\tpBase" "-I.\..\..\3part\opencv3.4.1\include" "-I.\..\..\3part\opencv3.4.1\include\opencv" "-I.\..\..\3part\opencv3.4.1\include\opencv2" "-I.\..\..\3part\lpCoreCtrl\include" "-I.\..\..\src\tpMain\algela" "-I.\..\..\src\ImageCompare" "-I.\..\..\src\interface" "-I.\..\..\3part\edcircle\include"</Command>
</CustomBuild>
<CustomBuild Include="QCamSettingDlg.h">
<AdditionalInputs Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(QTDIR)\bin\moc.exe;%(FullPath)</AdditionalInputs>
<Message Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Moc%27ing %(Identity)...</Message>
@ -419,6 +435,7 @@
<ClInclude Include="GeneratedFiles\ui_qaddchanneldlg.h" />
<ClInclude Include="GeneratedFiles\ui_qaddmodel.h" />
<ClInclude Include="GeneratedFiles\ui_qaddtimedlg.h" />
<ClInclude Include="GeneratedFiles\ui_QAlgParamDlg.h" />
<ClInclude Include="GeneratedFiles\ui_QCamSettingDlg.h" />
<ClInclude Include="GeneratedFiles\ui_qchannelmanager.h" />
<ClInclude Include="GeneratedFiles\ui_QChannelMgrDlg.h" />
@ -779,7 +796,6 @@
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|x64'">.\GeneratedFiles\$(ConfigurationName)\moc_%(Filename).cpp</Outputs>
<Command Condition="'$(Configuration)|$(Platform)'=='Release|x64'">"$(QTDIR)\bin\moc.exe" "%(FullPath)" -o ".\GeneratedFiles\$(ConfigurationName)\moc_%(Filename).cpp" -DUNICODE -DWIN32 -DWIN64 -DQT_NO_DEBUG -DNDEBUG -DQT_CORE_LIB -DTPMAIN_LIB -DTPMAIN_EXPORTS -DQT_GUI_LIB -DQT_WIDGETS_LIB -DQT_SQL_LIB -DQT_PRINTSUPPORT_LIB -DQT_NETWORK_LIB -DQT_SERIALPORT_LIB -D%(PreprocessorDefinitions) "-I." "-I.\GeneratedFiles" "-I.\GeneratedFiles\$(ConfigurationName)" "-I$(QTDIR)\include" "-I$(QTDIR)\include\QtCore" "-I$(QTDIR)\include\QtGui" "-I$(QTDIR)\include\QtWidgets" "-I$(QTDIR)\include\ActiveQt" "-I$(QTDIR)\include\QtSerialPort" "-I$(QTDIR)\include\QtANGLE" "-I$(QTDIR)\include\QtPrintSupport" "-I$(QTDIR)\include\QtSql" "-I$(QTDIR)\include\QtNetwork" "-I.\..\..\src\algorithm" "-I.\..\..\src\tpMain" "-I.\..\..\src\tpMain\thread" "-I.\..\..\src\tpMain\splashScreen" "-I.\..\..\src\tpMain\LightBoxwidget" "-I.\..\..\src\tpMain\QDiskCleanThread" "-I.\..\..\src\tpMain\QPixmapListBar" "-I.\..\..\src\userCtrl" "-I.\..\..\src\NetWheel" "-I.\..\..\src\RasterSDG20" "-I.\..\..\src\ReportModel" "-I.\..\..\3part\libzkq\include" "-I.\..\..\3part\tadpole\include\tpBase" "-I.\..\..\3part\opencv3.4.1\include" "-I.\..\..\3part\opencv3.4.1\include\opencv" "-I.\..\..\3part\opencv3.4.1\include\opencv2" "-I.\..\..\3part\lpCoreCtrl\include" "-I.\..\..\src\tpMain\algela" "-I.\..\..\src\ImageCompare" "-I.\..\..\src\interface" "-I.\..\..\3part\edcircle\include"</Command>
</CustomBuild>
<ClInclude Include="..\..\src\tpMain\ModelTrain.h" />
<ClInclude Include="..\..\src\tpMain\NetProtocol.h" />
<CustomBuild Include="..\..\src\tpMain\ProgressView.h">
<AdditionalInputs Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(QTDIR)\bin\moc.exe;%(FullPath)</AdditionalInputs>
@ -1291,6 +1307,16 @@
<ItemGroup>
<None Include="lpmain_en.ts" />
<None Include="lpmain_zh.ts" />
<CustomBuild Include="QAlgParamDlg.ui">
<AdditionalInputs Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(QTDIR)\bin\uic.exe;%(AdditionalInputs)</AdditionalInputs>
<Message Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Uic%27ing %(Identity)...</Message>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">.\GeneratedFiles\ui_%(Filename).h;%(Outputs)</Outputs>
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">"$(QTDIR)\bin\uic.exe" -o ".\GeneratedFiles\ui_%(Filename).h" "%(FullPath)"</Command>
<AdditionalInputs Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(QTDIR)\bin\uic.exe;%(AdditionalInputs)</AdditionalInputs>
<Message Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Uic%27ing %(Identity)...</Message>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|x64'">.\GeneratedFiles\ui_%(Filename).h;%(Outputs)</Outputs>
<Command Condition="'$(Configuration)|$(Platform)'=='Release|x64'">"$(QTDIR)\bin\uic.exe" -o ".\GeneratedFiles\ui_%(Filename).h" "%(FullPath)"</Command>
</CustomBuild>
</ItemGroup>
<PropertyGroup Label="Globals">
<ProjectGuid>{A229CF5C-81EF-4909-AB6E-49C746F1ED4C}</ProjectGuid>

@ -190,9 +190,6 @@
<ClCompile Include="GeneratedFiles\Release\moc_ModelTableView.cpp">
<Filter>Generated Files\Release</Filter>
</ClCompile>
<ClCompile Include="..\..\src\tpMain\ModelTrain.cpp">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="GeneratedFiles\Debug\moc_ProgressView.cpp">
<Filter>Generated Files\Debug</Filter>
</ClCompile>
@ -547,6 +544,15 @@
<ClCompile Include="QCamSettingDlg.cpp">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="GeneratedFiles\Debug\moc_QAlgParamDlg.cpp">
<Filter>Generated Files\Debug</Filter>
</ClCompile>
<ClCompile Include="GeneratedFiles\Release\moc_QAlgParamDlg.cpp">
<Filter>Generated Files\Release</Filter>
</ClCompile>
<ClCompile Include="QAlgParamDlg.cpp">
<Filter>Source Files</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\..\src\algorithm\ImageProcess.h">
@ -576,9 +582,6 @@
<ClInclude Include="..\..\src\tpMain\ModelManager.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="..\..\src\tpMain\ModelTrain.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="..\..\src\tpMain\resource.h">
<Filter>Header Files</Filter>
</ClInclude>
@ -696,6 +699,9 @@
<ClInclude Include="..\..\src\interface\Result2Ui.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="GeneratedFiles\ui_QAlgParamDlg.h">
<Filter>Generated Files</Filter>
</ClInclude>
</ItemGroup>
<ItemGroup>
<CustomBuild Include="..\..\src\tpMain\QDiskCleanThread\QDiskCleanThread.h">
@ -887,6 +893,12 @@
<CustomBuild Include="QCamSettingDlg.ui">
<Filter>Form Files</Filter>
</CustomBuild>
<CustomBuild Include="QAlgParamDlg.h">
<Filter>Header Files</Filter>
</CustomBuild>
<CustomBuild Include="QAlgParamDlg.ui">
<Filter>Form Files</Filter>
</CustomBuild>
</ItemGroup>
<ItemGroup>
<Image Include="..\..\src\tpMain\none.jpg">

@ -19,6 +19,8 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "tpCamBaumer", "..\..\Valve\
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "lpReport", "lpReport\lpReport.vcxproj", "{0E042214-1B06-40D6-9D20-C6D5FA3D7A51}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Net4Wheel", "Net4Wheel\Net4Wheel.vcxproj", "{9B718379-3719-4D4E-A903-EDE7EFB4DC65}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|x64 = Debug|x64
@ -77,6 +79,12 @@ Global
{0E042214-1B06-40D6-9D20-C6D5FA3D7A51}.Release|x64.ActiveCfg = Release|x64
{0E042214-1B06-40D6-9D20-C6D5FA3D7A51}.Release|x64.Build.0 = Release|x64
{0E042214-1B06-40D6-9D20-C6D5FA3D7A51}.Release|x86.ActiveCfg = Release|x64
{9B718379-3719-4D4E-A903-EDE7EFB4DC65}.Debug|x64.ActiveCfg = Debug|x64
{9B718379-3719-4D4E-A903-EDE7EFB4DC65}.Debug|x64.Build.0 = Debug|x64
{9B718379-3719-4D4E-A903-EDE7EFB4DC65}.Debug|x86.ActiveCfg = Debug|x64
{9B718379-3719-4D4E-A903-EDE7EFB4DC65}.Release|x64.ActiveCfg = Release|x64
{9B718379-3719-4D4E-A903-EDE7EFB4DC65}.Release|x64.Build.0 = Release|x64
{9B718379-3719-4D4E-A903-EDE7EFB4DC65}.Release|x86.ActiveCfg = Release|x64
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE

Loading…
Cancel
Save