From bc66b495f7a38886d481bd75a578e435df53e1e8 Mon Sep 17 00:00:00 2001
From: miyanhui <dennismi1024@gmail.com>
Date: 星期三, 13 二月 2019 17:32:36 +0800
Subject: [PATCH] 增加程序编译日期的代码

---
 QiaoJiaSystem/RapidStructureApp/main.cpp              |    2 +-
 QiaoJiaSystem/EncodeServer/main.cpp                   |    2 +-
 QiaoJiaSystem/UnitTest/main.cpp                       |    1 +
 QiaoJiaSystem/VideoToImageMulth/main.cpp              |    3 ++-
 QiaoJiaSystem/VideoAnalysFromHC/main.cpp              |    2 +-
 QiaoJiaSystem/VideoServer/QiaoJia/main.cpp            |    2 +-
 QiaoJiaSystem/StructureApp/AppPipeController.cpp      |   19 ++++++++++++-------
 QiaoJiaSystem/YoloServer/main.cpp                     |    1 +
 QiaoJiaSystem/DataManagerServer/demo.cpp              |    2 +-
 QiaoJiaSystem/VideoToImage/main.cpp                   |    2 +-
 QiaoJiaSystem/FaceSearchServer/main.cpp               |    2 +-
 QiaoJiaSystem/DataManagerServer/http_configserver.cpp |    4 ++--
 QiaoJiaSystem/FaceDetectServer/main.cpp               |    1 +
 QiaoJiaSystem/RecordVideo/main.cpp                    |    2 +-
 QiaoJiaSystem/LocalDBTool/main.cpp                    |    2 +-
 QiaoJiaSystem/PerimeterAlarm/main.cpp                 |    2 +-
 16 files changed, 29 insertions(+), 20 deletions(-)

diff --git a/QiaoJiaSystem/DataManagerServer/demo.cpp b/QiaoJiaSystem/DataManagerServer/demo.cpp
index 9334952..8907a69 100644
--- a/QiaoJiaSystem/DataManagerServer/demo.cpp
+++ b/QiaoJiaSystem/DataManagerServer/demo.cpp
@@ -24,7 +24,7 @@
 //
 //    a.stop();
 //    a.wait();
-
+    std::cout<<__DATE__<<" "<<__TIME__<<std::endl;
     string img = "http://192.168.1.182:8080/ManCarAnaly/group2/M00/02/B5/wKgBnFw3TB-AfsrIAAah4WWyHJ0555.jpg";
 
     auto pos = img.find("group");
diff --git a/QiaoJiaSystem/DataManagerServer/http_configserver.cpp b/QiaoJiaSystem/DataManagerServer/http_configserver.cpp
index 27e432c..54a887b 100644
--- a/QiaoJiaSystem/DataManagerServer/http_configserver.cpp
+++ b/QiaoJiaSystem/DataManagerServer/http_configserver.cpp
@@ -2528,7 +2528,7 @@
             std::string picDate = value["picDate"].asString();
             std::string imgKey = value["imgKey"].asString();
             //鍏煎鏃х増鏈�
-            if(imgKey=="undefined")
+            if(imgKey=="undefined" || imgKey.empty())
             {
                 return getAlarmImageByPicDateAndDevId(picDate,devId,response);
             }   
@@ -2644,7 +2644,7 @@
         std::string path;
 
         //鍏煎鏃х増鏈�
-        if(imgKey=="undefined")
+        if(imgKey=="undefined"||imgKey.empty())
         {
             qint64 sub;
             path = getVideoPathByPicDate(picDate,devId,sub);
diff --git a/QiaoJiaSystem/EncodeServer/main.cpp b/QiaoJiaSystem/EncodeServer/main.cpp
index 71056e1..fe839d4 100644
--- a/QiaoJiaSystem/EncodeServer/main.cpp
+++ b/QiaoJiaSystem/EncodeServer/main.cpp
@@ -28,7 +28,7 @@
 int main(int argc, char **argv) {
     SAVE_APP_ARGS
     ENABLEGLOG(GET_STR_CONFIG("logPath").c_str());
-
+    std::cout<<__DATE__<<" "<<__TIME__<<std::endl;
     EncodeVideoManager  encodeVideoManager;
     encodeVideoManager.start();
 
diff --git a/QiaoJiaSystem/FaceDetectServer/main.cpp b/QiaoJiaSystem/FaceDetectServer/main.cpp
index 2529adc..425bdde 100644
--- a/QiaoJiaSystem/FaceDetectServer/main.cpp
+++ b/QiaoJiaSystem/FaceDetectServer/main.cpp
@@ -4,6 +4,7 @@
 #include <basic/util/app/AppPreference.hpp>
 #include "FaceDetectServerI.h"
 int main(int argc,char** argv) {
+    std::cout<<__DATE__<<" "<<__TIME__<<std::endl;
 #ifdef DEBUG
     argc = 2;
     const char* home = argv[0];
diff --git a/QiaoJiaSystem/FaceSearchServer/main.cpp b/QiaoJiaSystem/FaceSearchServer/main.cpp
index 90f7577..bfbebd2 100644
--- a/QiaoJiaSystem/FaceSearchServer/main.cpp
+++ b/QiaoJiaSystem/FaceSearchServer/main.cpp
@@ -14,7 +14,7 @@
 using namespace std;
 
 int main(int argc, char **argv) {
-
+    std::cout<<__DATE__<<" "<<__TIME__<<std::endl;
     SAVE_APP_ARGS;
     ENABLEGLOG(GET_STR_CONFIG("logPath").c_str());
     auto ich = Ice::initialize(argc, argv);
diff --git a/QiaoJiaSystem/LocalDBTool/main.cpp b/QiaoJiaSystem/LocalDBTool/main.cpp
index 8f3d590..7b96c2f 100644
--- a/QiaoJiaSystem/LocalDBTool/main.cpp
+++ b/QiaoJiaSystem/LocalDBTool/main.cpp
@@ -241,7 +241,7 @@
 
 int main(int argc, char **argv) {
     ENABLEGLOG(GET_STR_CONFIG("logPath").c_str());
-
+    std::cout<<__DATE__<<" "<<__TIME__<<std::endl;
     std::string m = "test";
     DBG(m << " DBG");
     DBG(m << " DBG");
diff --git a/QiaoJiaSystem/PerimeterAlarm/main.cpp b/QiaoJiaSystem/PerimeterAlarm/main.cpp
index d54f890..a615147 100644
--- a/QiaoJiaSystem/PerimeterAlarm/main.cpp
+++ b/QiaoJiaSystem/PerimeterAlarm/main.cpp
@@ -9,7 +9,7 @@
 
 int main(int argc, char **argv) {
     SAVE_APP_ARGS;
-
+    std::cout<<__DATE__<<" "<<__TIME__<<std::endl;
 #ifdef GLOG
     ENABLEGLOG("./log/");
 #endif
diff --git a/QiaoJiaSystem/RapidStructureApp/main.cpp b/QiaoJiaSystem/RapidStructureApp/main.cpp
index d4192b9..c1b710a 100644
--- a/QiaoJiaSystem/RapidStructureApp/main.cpp
+++ b/QiaoJiaSystem/RapidStructureApp/main.cpp
@@ -5,7 +5,7 @@
 using namespace std;
 
 int main(int argc, char **argv) {
-
+    std::cout<<__DATE__<<" "<<__TIME__<<std::endl;
     vector<string> vec;
     vec.push_back("/home/bsk/test/1/load/");
 //    vec.push_back("/home/bsk/2/load/");
diff --git a/QiaoJiaSystem/RecordVideo/main.cpp b/QiaoJiaSystem/RecordVideo/main.cpp
index 78d3b33..4396e2d 100644
--- a/QiaoJiaSystem/RecordVideo/main.cpp
+++ b/QiaoJiaSystem/RecordVideo/main.cpp
@@ -47,7 +47,7 @@
 #include "jsoncpp/json/json.h"
 
 int main(int argc, char **argv) {
-
+    std::cout<<__DATE__<<" "<<__TIME__<<std::endl;
     SAVE_APP_ARGS;
     ENABLEGLOG(GET_STR_CONFIG("logPath").c_str());
     auto ich = Ice::initialize(argc, argv);
diff --git a/QiaoJiaSystem/StructureApp/AppPipeController.cpp b/QiaoJiaSystem/StructureApp/AppPipeController.cpp
index d13a670..7fd95c9 100644
--- a/QiaoJiaSystem/StructureApp/AppPipeController.cpp
+++ b/QiaoJiaSystem/StructureApp/AppPipeController.cpp
@@ -217,6 +217,7 @@
         }
     }
     else {
+        INFO("ImageNoFace Yolo:"<<imgKeyYolo<<"   Face:"<<imgKeyFace);
         INFO("faceRpcElement: "<< faceRpcElement.getTriggerState() <<" "<<
                                "personElement: "<<personElement.getTriggerState() <<"  "<<
                                "leftJudgment: "<<leftJudgment.getTriggerState() <<"   "<<
@@ -307,8 +308,8 @@
                 imageDrawElement.setImage(imageTemp);
                 imageDrawElement.submit();
             }
-
-            /*if(faceRpcElement.getTriggerState() ||
+            //this->RecordVideo();
+            if(faceRpcElement.getTriggerState() ||
                  personElement.getTriggerState() ||
                  leftJudgment.getTriggerState() ||
                  rightJudgment.getTriggerState() ||
@@ -342,7 +343,7 @@
                     "crowdElement: "<<crowdElement.getTriggerState()<<"   "<<
                     "perHubElement: "<<perHubElement.getTriggerState()<<"   "<<
                     "perStaticElement: "<<perStaticElement.getTriggerState());
-            }*/
+            }
         }
     });
 
@@ -353,18 +354,20 @@
             personElement.setObjsResults(yoloRpcElement.getLastScoreRects());
             personElement.submit();
         }
-        INFO("Record Video By Yolo");
-        this->RecordVideo();
+        //INFO("Record Video By Yolo");
+        //this->RecordVideo();
     });
 
     faceRpcElement.registerConnector([&] {
         imageDrawElement.setFaces(faceRpcElement.getLastScoreRects());
-        INFO("Record Video By Face");
-        this->RecordVideo();
+        //INFO("Record Video By Face");
+        //this->RecordVideo();
     });
 
     yoloRpcElement.registerConnector("YoloTrigger", [&] {
 //        auto images = yoloRpcElement.getTriggerMats();
+        //INFO("Record Video By Yolo");
+        //this->RecordVideo();
     });
 
     faceRpcElement.registerConnector("FaceTrigger", [&] {
@@ -375,6 +378,8 @@
                                               faceRpcElement.getTriggerFaces(),
                                               faceRpcElement.getTriggerScoreRects(),
                                               faceRpcElement.getTriggerMats()});
+        //INFO("Record Video By Face");
+        //this->RecordVideo();
     });
 
     imageDrawElement.registerConnector([&] {
diff --git a/QiaoJiaSystem/UnitTest/main.cpp b/QiaoJiaSystem/UnitTest/main.cpp
index dd48dbc..ba78ed0 100644
--- a/QiaoJiaSystem/UnitTest/main.cpp
+++ b/QiaoJiaSystem/UnitTest/main.cpp
@@ -6,6 +6,7 @@
 #include "doctest.h"
 
 int main(int argc, char** argv) {
+    std::cout<<__DATE__<<" "<<__TIME__<<std::endl;
     doctest::Context context;
 
     // !!! THIS IS JUST AN EXAMPLE SHOWING HOW DEFAULTS/OVERRIDES ARE SET !!!
diff --git a/QiaoJiaSystem/VideoAnalysFromHC/main.cpp b/QiaoJiaSystem/VideoAnalysFromHC/main.cpp
index a28cb72..0f695e3 100644
--- a/QiaoJiaSystem/VideoAnalysFromHC/main.cpp
+++ b/QiaoJiaSystem/VideoAnalysFromHC/main.cpp
@@ -66,7 +66,7 @@
 
 int main(int argc, char **argv) {
     SAVE_APP_ARGS
-
+    std::cout<<__DATE__<<" "<<__TIME__<<std::endl;
 #ifdef GLOG
         ENABLEGLOG(GET_STR_CONFIG("logPath").c_str());
 #endif
diff --git a/QiaoJiaSystem/VideoServer/QiaoJia/main.cpp b/QiaoJiaSystem/VideoServer/QiaoJia/main.cpp
index be0bab1..803b03b 100644
--- a/QiaoJiaSystem/VideoServer/QiaoJia/main.cpp
+++ b/QiaoJiaSystem/VideoServer/QiaoJia/main.cpp
@@ -15,7 +15,7 @@
 
 int main(int argc, char *argv[])
 {
-
+    std::cout<<__DATE__<<" "<<__TIME__<<std::endl;
     {
         CallBackFunc callf;
 
diff --git a/QiaoJiaSystem/VideoToImage/main.cpp b/QiaoJiaSystem/VideoToImage/main.cpp
index d18fc30..e481224 100644
--- a/QiaoJiaSystem/VideoToImage/main.cpp
+++ b/QiaoJiaSystem/VideoToImage/main.cpp
@@ -27,7 +27,7 @@
 
 int main(int argc, char **argv) {
     SAVE_APP_ARGS
-
+    std::cout<<__DATE__<<" "<<__TIME__<<std::endl;
 #ifdef GLOG
         ENABLEGLOG(GET_STR_CONFIG("logPath").c_str());
 #endif
diff --git a/QiaoJiaSystem/VideoToImageMulth/main.cpp b/QiaoJiaSystem/VideoToImageMulth/main.cpp
index cc180d0..ec98d46 100644
--- a/QiaoJiaSystem/VideoToImageMulth/main.cpp
+++ b/QiaoJiaSystem/VideoToImageMulth/main.cpp
@@ -26,6 +26,7 @@
 
 
 int main(int argc, char **argv) {
+    std::cout<<__DATE__<<" "<<__TIME__<<std::endl;
     SAVE_APP_ARGS
 
 #ifdef GLOG
@@ -35,7 +36,7 @@
     appPref.setLongData("gpu.index", 1);
     appPref.setIntData("show.image", 0);
 
-    std::cout<<__DATE__<<std::endl;
+
 
 //    LDBTool _dbTool;
 //    thread startRtspAnalys(startManager, &_dbTool);
diff --git a/QiaoJiaSystem/YoloServer/main.cpp b/QiaoJiaSystem/YoloServer/main.cpp
index 20f2a6c..238a50f 100644
--- a/QiaoJiaSystem/YoloServer/main.cpp
+++ b/QiaoJiaSystem/YoloServer/main.cpp
@@ -7,6 +7,7 @@
 #include <basic/util/app/AppConfig.h>
 
 int main(int argc, char **argv) {
+    std::cout<<__DATE__<<" "<<__TIME__<<std::endl;
     SAVE_APP_ARGS;
     ENABLEGLOG(GET_STR_CONFIG("logPath").c_str());
     auto ich = Ice::initialize(argc, argv);

--
Gitblit v1.8.0