汉王库调整
This commit is contained in:
parent
7348f9c06c
commit
604bda6294
|
@ -763,11 +763,18 @@ namespace hg_imgproc
|
|||
#define test
|
||||
int ocr_auto_txtdirect()
|
||||
{
|
||||
int pDirect = -1;
|
||||
int ret = SCANNER_ERR_OK;
|
||||
void *pHanld = NULL;
|
||||
std::vector<cv::Mat> mats(mats_);
|
||||
mats_.clear();
|
||||
string scanner_path = hg_log::get_module_full_path("libhwocrdetect.so");
|
||||
int pDirect = -1;
|
||||
int ret = SCANNER_ERR_OK;
|
||||
void *pHanld = NULL;
|
||||
|
||||
std::vector<cv::Mat> mats(mats_);
|
||||
mats_.clear();
|
||||
|
||||
if(scanner_path.empty())
|
||||
{
|
||||
return SCANNER_ERR_OUT_OF_RANGE;
|
||||
}
|
||||
|
||||
#if ((!defined x86_64) && (!defined WIN32))
|
||||
//linux x86_64 暂时没有OCR三方
|
||||
|
@ -794,10 +801,10 @@ namespace hg_imgproc
|
|||
typedef int (*sdkinit)(void *);
|
||||
typedef int (*sdkgetfiledirectimage)(unsigned char*pbImage, int nWidth, int nHeight, TColorType nColorType, void *pstHandle, int *pDirect);
|
||||
typedef int (*sdkexit)(void *);
|
||||
void *hanlde = dlopen("/home/hg/sane/release/kylin/mips64/libhwocrdetect.so",RTLD_LAZY);
|
||||
void *hanlde = dlopen(scanner_path.c_str(),RTLD_LAZY);
|
||||
if(!hanlde)
|
||||
{
|
||||
return -1;
|
||||
return SCANNER_ERR_OUT_OF_RANGE;
|
||||
}
|
||||
sdkinit init = (sdkinit)dlsym(hanlde , "HWOCR_SDKInitialize");
|
||||
sdkgetfiledirectimage d = (sdkgetfiledirectimage)dlsym(hanlde , "HWOCR_GetFileDirectImage");
|
||||
|
|
Loading…
Reference in New Issue