| | |
| | | // |
| | | // |
| | | // Created by basic on 18-8-24. |
| | | // |
| | | |
| | |
| | | #include <map> |
| | | #include <list> |
| | | #include <opencv2/opencv.hpp> |
| | | #include <basic/pipe/TimerElement.h> |
| | | //#include <basic/pipe/TimerElement.h> |
| | | #include "YoloRpcElement.h" |
| | | #include <QSharedMemory> |
| | | #include <QString> |
| | |
| | | #include "DBStruct.h" |
| | | #include <basic/db/Elasticsearch/EsDBTool.h> |
| | | #include <jsoncpp/json/json.h> |
| | | |
| | | #include <basic/pipe/PipeElement.h> |
| | | struct VectorPoint { |
| | | cv::Point2f start_Point; |
| | | cv::Point2f end_Point; |
| | | cv::Point2i start_Point; |
| | | cv::Point2i end_Point; |
| | | }; |
| | | |
| | | typedef VectorPoint BaseLine; |
| | |
| | | } |
| | | |
| | | |
| | | class JudgmentRetrogradeTool : public TimerElement { |
| | | class JudgmentRetrogradeTool : public basic::PipeElement{ |
| | | public: |
| | | JudgmentRetrogradeTool() : TimerElement(1000) {} |
| | | JudgmentRetrogradeTool() {} |
| | | |
| | | JudgmentRetrogradeTool(const SdkRule &rule); |
| | | |
| | |
| | | void setImage(const cv::Mat &value); |
| | | |
| | | private: |
| | | bool setMask(QString area, QString line); |
| | | |
| | | void setPerPoint(const long &, cv::Point2f); |
| | | |
| | | void setPerRect(const long &, cv::Rect rect); |
| | |
| | | |
| | | private: |
| | | // virtual void threadInitial() override; |
| | | virtual void timerFunc() override; |
| | | virtual void threadFunc()override; |
| | | // virtual void timerFunc() override; |
| | | // virtual void threadClosing()override; |
| | | |
| | | private: |
| | |
| | | std::map<long, std::list<float>> m_mapPerDirection; |
| | | |
| | | //跟踪id,逆行状态 |
| | | std::map<long, bool> m_mapPerRet; |
| | | // std::map<long, bool> m_mapPerRet; |
| | | std::map<long, int> m_mapPerRet; |
| | | |
| | | QPolygon m_polygon; |
| | | |
| | |
| | | |
| | | cv::Mat image; |
| | | EsDBTool *pManagerEsDB; |
| | | cv::Point2i* pointArray; |
| | | |
| | | int npts; |
| | | QString m_area; |
| | | QString m_line; |
| | | bool m_bSetWH; |
| | | }; |
| | | |
| | | |