admin
2022-07-07 30f434d78b58e3a4198cf5ba5a9e5a0ce1cd5292
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
#pragma once
#include <string>
#include <list>
#include <iostream>
#include <opencv2/opencv.hpp>
#include <opencv2/highgui.hpp>
#include <opencv2/core.hpp>
#include <opencv2/imgcodecs.hpp> 
#include "CaptureUtil.h"
#include "RecognitionManager.h"
enum ImgType
{
    IMG_TYPE_GP,
    IMG_TYPE_ADD
};
struct GPCodeArea
{
    ImgType type;
    int startx;
    int starty;
    int endx;
    int endy;
    std::string code;
 
    //L2Êý¾ÝÓÐЧ
    int cateIndex;
};
//ͬ»¨Ë³Ê¼þ
class THSActionUtil
{
private:
    static RecognitionManager *recognitionManager;
    static void addGP(string code);
    static std::list<GPCodeArea> getListenL2GP();
 
public:
 
    static HWND getL2Win();
 
    //¼ì²â»·¾³
    static bool checkEnv();
 
    //´ò¿ªÍ¬»¨Ë³µÄ¸±ÆÁÄ»
    static void openSecondScreen();
    //ÉèÖÃ¹ÉÆ±
    static bool setGP(std::string quickCode, list<std::string> codeList);
    //ʶ±ð¹ÉƱ´úÂë
    static std::list<GPCodeArea>  recognitionGPArea(cv::Mat img);
 
    //ʶ±ðÊý×Ö
    static std::list<GPCodeArea>  recognitionNum(cv::Mat img,std::list<GPCodeArea> areaList);
 
    //ʶ±ð´úÂë
    static std::list<string> recognitionGPCode(cv::Mat img);
 
 
    //ÉèÖûñÈ¡level2µÄ¹ÉƱÊý¾Ý
    static bool setListenL2GP(int p,string code);
 
    //ÉèÖûñÈ¡level2µÄ¹ÉƱ´úÂë
    static std::map<int, string> getListenL2GPCodes();
 
 
 
 
 
 
 
    
 
 
};