diff --git a/Cigarette.sln b/Cigarette.sln index 243d8ea..22874c0 100644 --- a/Cigarette.sln +++ b/Cigarette.sln @@ -26,7 +26,7 @@ Global HideSolutionNode = FALSE EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution - SolutionGuid = {0AF1A30E-A12C-4014-ACD5-65A1E6D54D46} Qt5Version = 5.15.2_msvc2019_64 + SolutionGuid = {0AF1A30E-A12C-4014-ACD5-65A1E6D54D46} EndGlobalSection EndGlobal diff --git a/Cigarette/Cigarette.vcxproj.user b/Cigarette/Cigarette.vcxproj.user index 02760dc..633ab6d 100644 --- a/Cigarette/Cigarette.vcxproj.user +++ b/Cigarette/Cigarette.vcxproj.user @@ -2,11 +2,11 @@ - D:\Qt\5.15.2\msvc2019_64 + C:\Qt\5.15.2\msvc2019_64 PATH=$(QTDIR)\bin%3bD:\Qt\5.15.2\msvc2019_64\bin%3b$(PATH) - D:\Qt\5.15.2\msvc2019_64 + C:\Qt\5.15.2\msvc2019_64 PATH=$(QTDIR)\bin%3bD:\Qt\5.15.2\msvc2019_64\bin%3b$(PATH) \ No newline at end of file diff --git a/Cigarette/cigarette.cpp b/Cigarette/cigarette.cpp index 1a1a664..4c70618 100644 --- a/Cigarette/cigarette.cpp +++ b/Cigarette/cigarette.cpp @@ -247,10 +247,6 @@ Cigarette::Cigarette(QWidget *parent) rThread->init(g_sys_conf.MonitorIP ,g_sys_conf.MonitorPort); connect(rThread, &threadReceive::sendMsgToCigratte, this, &Cigarette::recMsgFromUdp); rThread->start_work(); - - sThread.sendData("ReStartOk", g_sys_conf.FeedbackPort); - sThread.sendData("DebugDis", g_sys_conf.FeedbackPort); - sThread.sendData("LockOk", g_sys_conf.FeedbackPort); #endif #ifdef __ExportData @@ -289,11 +285,6 @@ Cigarette::Cigarette(QWidget *parent) EnumerateCameras((SingleCamInfoStruct*)&SingleCamInfo,true,g_sys_conf); - /*if (!license_pass) 授权检查失败 - { - QMessageBox::information(NULL, QStringLiteral("授权检查失败"), QStringLiteral("授权检查失败,请联系系统供应商!"), QMessageBox::Ok); - exit(0); - }*/ // 剔除值清0 int ret = m_PLCDevice->write_bit_2_plc(g_modbus_conf.shift, 1);//给PLC发送换班消息 @@ -388,7 +379,11 @@ Cigarette::Cigarette(QWidget *parent) } } } - +#ifdef __UDPSend + sThread.sendData("ReStartOk", g_sys_conf.FeedbackPort); + sThread.sendData("DebugDis", g_sys_conf.FeedbackPort); + sThread.sendData("LockOk", g_sys_conf.FeedbackPort); +#endif DisableDebugMode(); m_pTimer = new QTimer(this); diff --git a/Cigarette/common.h b/Cigarette/common.h index 5e7ac6a..26ad18e 100644 --- a/Cigarette/common.h +++ b/Cigarette/common.h @@ -21,7 +21,7 @@ #endif //#define identify_Hik_YSXID//识别海康相机YSXID //#define __ExportData // 输出检测数据到XML文档 -#define DRAW_RECT // 鼠标画框功能 +//#define DRAW_RECT // 鼠标画框功能 #define Queue_Size 15 #define Unit_Queue_Size Queue_Size*3 diff --git a/Cigarette/output_statistic.cpp b/Cigarette/output_statistic.cpp index 50ff240..5dddfbc 100644 --- a/Cigarette/output_statistic.cpp +++ b/Cigarette/output_statistic.cpp @@ -48,56 +48,56 @@ void output_statistic::recMsgFromDialogSetup() } #else - QFile file("../conf/camera0_statistic.txt"); + QFile file("D:/conf/camera0_statistic.txt"); if (file.open(QIODevice::ReadOnly | QIODevice::Text)) { QTextStream in(&file); ui.textBrowser_1->setText(in.readAll()); } file.close(); - file.setFileName("../conf/camera1_statistic.txt"); + file.setFileName("D:/conf/camera1_statistic.txt"); if (file.open(QIODevice::ReadOnly | QIODevice::Text)) { QTextStream in(&file); ui.textBrowser_2->setText(in.readAll()); } file.close(); - file.setFileName("../conf/camera2_statistic.txt"); + file.setFileName("D:/conf/camera2_statistic.txt"); if (file.open(QIODevice::ReadOnly | QIODevice::Text)) { QTextStream in(&file); ui.textBrowser_3->setText(in.readAll()); } file.close(); - file.setFileName("../conf/camera3_statistic.txt"); + file.setFileName("D:/conf/camera3_statistic.txt"); if (file.open(QIODevice::ReadOnly | QIODevice::Text)) { QTextStream in(&file); ui.textBrowser_4->setText(in.readAll()); } file.close(); - file.setFileName("../conf/camera4_statistic.txt"); + file.setFileName("D:/conf/camera4_statistic.txt"); if (file.open(QIODevice::ReadOnly | QIODevice::Text)) { QTextStream in(&file); ui.textBrowser_5->setText(in.readAll()); } file.close(); - file.setFileName("../conf/camera5_statistic.txt"); + file.setFileName("D:/conf/camera5_statistic.txt"); if (file.open(QIODevice::ReadOnly | QIODevice::Text)) { QTextStream in(&file); ui.textBrowser_6->setText(in.readAll()); } file.close(); - file.setFileName("../conf/camera6_statistic.txt"); + file.setFileName("D:/conf/camera6_statistic.txt"); if (file.open(QIODevice::ReadOnly | QIODevice::Text)) { QTextStream in(&file); ui.textBrowser_7->setText(in.readAll()); } file.close(); - file.setFileName("../conf/camera7_statistic.txt"); + file.setFileName("D:/conf/camera7_statistic.txt"); if (file.open(QIODevice::ReadOnly | QIODevice::Text)) { QTextStream in(&file); diff --git a/Cigarette/threadSend.cpp b/Cigarette/threadSend.cpp index 3feaaa9..2550e66 100644 --- a/Cigarette/threadSend.cpp +++ b/Cigarette/threadSend.cpp @@ -82,7 +82,8 @@ void threadSend::sendImage(_UDPSendInfo *UDPSendInfo,int port) cv::Mat mat = UDPSendInfo->image; char cnt = UDPSendInfo->cnt; - cv::resize(mat, mat, cv::Size(image_width, image_heigh)); + //cv::resize(mat, mat, cv::Size(image_width, image_heigh)); + cv::resize(mat, mat, cv::Size(image_width, image_heigh),4,4,2); int length = image_width * image_heigh * 3; char* data = (char*)malloc(sizeof(char) * length + 1);