//my test method error is : no matching constructor for initialization of 'idlibrary::mrz::reader'
BOOST_AUTO_TEST_CASE(mrtd_type2)
{
idlibrary::ocr::engine_ptr engine(new idsmart::ocr::tesseract_engine(ocr_path().c_str()));
BOOST_REQUIRE(engine);
idlibrary::mrz::reader reader(engine); //having error right here
idlibrary::mrz::document_ptr document(reader.read(image_path("mrz-mrtd-type2.jpg").c_str()));
BOOST_REQUIRE(document->valid());
}
//my.cpp file
class reader
{
public:
typedef boost::function<void(std::vector<cv::Point> corners)> DetectionCallback;
reader(idlibrary::ocr::engine_ptr engine_ptr, idlibrary::mrz::detector_ptr detector_ptr);
// unused, required for PIMPL idiom
~reader();
std::unique_ptr<idlibrary::mrz::result> read(const char* path);
std::unique_ptr<idlibrary::mrz::result> read(const cv::Mat mat);
std::unique_ptr<idlibrary::mrz::result> detect_and_read(const char* path);
std::unique_ptr<idlibrary::mrz::result> detect_and_read(const cv::Mat mat);
std::unique_ptr<idlibrary::mrz::result> detect_and_read(const cv::Mat mat, DetectionCallback callback);
Aucun commentaire:
Enregistrer un commentaire