mirror of http://192.168.1.51:8099/lmh188/twain3.0
24 lines
863 B
C++
24 lines
863 B
C++
#pragma once
|
|
#include <opencv2/opencv.hpp>
|
|
#include "ImageProcess/ImageProcess_Public.h"
|
|
#include <map>
|
|
|
|
class ImageApplyUV
|
|
{
|
|
public:
|
|
ImageApplyUV();
|
|
~ImageApplyUV();
|
|
void Apply(cv::Mat& image, const cv::Mat& uv, int dpi = 200, int thresh = 100);
|
|
|
|
static cv::Mat Apply(const cv::Mat& image, const cv::Mat& uv, const cv::RotatedRect& uvRoi, bool isDesaskew, int angle, int pixtype);
|
|
private:
|
|
void purgeQR_kernal(cv::Mat& image, const cv::Rect& roi, std::map<int, cv::Scalar> map_color, int dpi, int threshold);
|
|
void findContours1(const cv::Mat& src, std::vector<std::vector<cv::Point>>& contours, std::vector<cv::Vec4i>& hierarchy,
|
|
int retr = cv::RETR_LIST, int method = cv::CHAIN_APPROX_SIMPLE, cv::Point offset = cv::Point(0, 0));
|
|
cv::Scalar getColor(const cv::Mat& image, int col, int threshold);
|
|
void update_lutData(int contrast);
|
|
cv::Mat lut;
|
|
};
|
|
|
|
|