 |
SaigeVision C/C++
1.4.7
SaigeVision API document for C/C++
|
|
Go to the documentation of this file.
10 #define DLLTYPE_OCR extern "C" __declspec(dllexport)
12 #define DLLTYPE_OCR extern "C" __declspec(dllimport)
77 const char* ocrTextFilePath);
87 const wchar_t* ocrTextFilePath);
132 int* scoreThreshold);
142 bool writeOnModelFile =
true);
172 bool writeOnModelFile =
true);
198 wchar_t* charsToExclude,
199 bool writeOnModelFile =
true);
218 int maxInspectionHeight,
219 int maxInspectionWidth,
220 bool writeOnModelFile =
true);
230 int* maxInspectionHeight,
231 int* maxInspectionWidth);
247 float* forwardTimeLimit);
255 bool* bIsToUseForwardTimeLimit);
266 float* forwardTimeLimit,
267 bool* bIsToUseForwardTimeLimit);
276 float forwardTimeLimit,
277 bool writeOnModelFile =
true);
286 bool bIsToUseForwardTimeLimit,
287 bool writeOnModelFile =
true);
299 float forwardTimeLimit,
300 bool bIsToUseForwardTimeLimit,
301 bool writeOnModelFile =
true);
325 const char* imagePath,
334 const wchar_t* imagePath,
346 const void* imageData,
383 int* numberOfOCRTextBoxes);
398 long* inspectionTimeInLong);
405 double* inspectionTimeInDouble);
412 long* imageLoadingTimeInLong);
419 double* imageLoadingTimeInDouble);
455 float* rectMaskXMin,
float* rectMaskYMin,
float* rectMaskWidth,
float* rectMaskHeight,
int numOfEllipseMask,
456 float* ellipseMaskXMin,
float* ellipseMaskYMin,
float* ellipseMaskWidth,
float* ellipseMaskHeight,
bool writeOnModelFile =
true);
eErrorType SR_SetOCRTestCharsToExclude(OCRTestHandle handle, int nCharsToExclude, wchar_t *charsToExclude, bool writeOnModelFile=true)
Set OCR's excluded characters.
eErrorType SR_DestroyOCRTestHandle(OCRTestHandle handle)
Destruct a OCRTestHandle.
eErrorType SR_GetOCRTestInspectionTime(OCRTestResult ocrTestResult, long *inspectionTimeInLong)
Get the inspection time.
eErrorType SR_GetOCRTestMaxInspectionSize(OCRTestHandle handle, int *maxInspectionHeight, int *maxInspectionWidth)
Get OCR's max inspection size.
eErrorType SR_GetOCRTestAlgorithmType(OCRTestHandle handle, eAlgorithmType *boxAlgoTypeOut, eAlgorithmType *textAlgoTypeOut)
Get a algorithm type(ex, standard, deep) of OCR models.
eErrorType SR_ApplyOCRTestFromImageFileByWideCharPath(OCRTestHandle handle, const wchar_t *imagePath, OCRTestResult ocrTestResult)
Apply OCR algorithm to image by file path.
eErrorType SR_LoadOCRTestNetworkInGPU(OCRTestHandle handle, int GPUNumber)
Allocate required cpu & gpu memory.
eErrorType SR_GetOCRTestLoadImageTime(OCRTestResult ocrTestResult, long *imageLoadingTimeInLong)
Get the image loading time.
void * OCRTestResult
OCR inspection results handler.
Definition: OCRTestDLL.h:67
eErrorType SR_SetOCRTestAreaThreshold(OCRTestHandle handle, int areaThreshold, bool writeOnModelFile=true)
Get OCR's area threshold.
eErrorType SR_SetOCRTestResizeFactor(OCRTestHandle handle, float resizeFactor, bool writeOnModelFile)
Set resize factor for default model.
eErrorType SR_GetOCRTestInspectionTimeInDouble(OCRTestResult ocrTestResult, double *inspectionTimeInDouble)
Get the inspection time.
eErrorType SR_SetOCRTestScoreThreshold(OCRTestHandle handle, int scoreThreshold, bool writeOnModelFile=true)
Set OCR's score threshold.
eErrorType SR_GetOCRTestAreaThreshold(OCRTestHandle handle, int *areaThreshold)
Get OCR's area threshold.
eErrorType SR_DeleteOCRTestResult(OCRTestResult ocrTestResult)
Destruct a OCRTestResult.
eErrorType SR_WriteOCRTestOptionsOnModelFile(OCRTestHandle handle)
Write inspection options(OCR's area threshold, OCR's score threshold) on model file.
eErrorType SR_GetOCRTestIsToUseForwardTimeLimit(OCRTestHandle handle, bool *bIsToUseForwardTimeLimit)
Get the boolean whether the current model is using time limit or not.
eErrorType SR_SetOCRTestOptionsAsDefault(OCRTestHandle handle)
Reset inspection options(OCR's area threshold, OCR's score threshold) as default values.
eErrorType SR_ApplyOCRTestFrom8bitImageData(OCRTestHandle handle, const void *imageData, const int height, const int width, const int channels, OCRTestResult ocrTestResult)
Apply OCR algorithm to 1 or 3 or 4 channels image by 8-bit data.
eErrorType SR_GetOCRTestScoreThreshold(OCRTestHandle handle, int *scoreThreshold)
Get OCR's score threshold.
OCRTestResult SR_MakeOCRTestResult()
Construct a OCRTestResult.
eErrorType SR_PrintOCRTestParameters(OCRTestHandle handle)
Print a model parameters (inspection options...)
OCRTestHandle SR_CreateOCRTestHandleByWideCharPath(const wchar_t *ocrBoxFilePath, const wchar_t *ocrTextFilePath)
Create a OCRTestHandle via wide char path.
eErrorType SR_SetOCRTestIsToUseForwardTimeLimit(OCRTestHandle handle, bool bIsToUseForwardTimeLimit, bool writeOnModelFile=true)
Set the boolean whether the current model is using time limit or not.
eErrorType SR_GetOCRTestNumberOfTextBoxes(OCRTestResult ocrTestResult, int *numberOfOCRTextBoxes)
Get the number of SR_OCRTextBox.
eErrorType SR_ApplyOCRTestFromImageFile(OCRTestHandle handle, const char *imagePath, OCRTestResult ocrTestResult)
Apply OCR algorithm to image by file path.
eErrorType SR_SetOCRTestForwardTimeLimitVariables(OCRTestHandle handle, float forwardTimeLimit, bool bIsToUseForwardTimeLimit, bool writeOnModelFile=true)
Set the Forward time limit variables.
eErrorType SR_SetOCRTestROIParameters(OCRTestHandle handle, int roiType, float *simpleROIParams, int *adROIParams, int numOfRectMask, float *rectMaskXMin, float *rectMaskYMin, float *rectMaskWidth, float *rectMaskHeight, int numOfEllipseMask, float *ellipseMaskXMin, float *ellipseMaskYMin, float *ellipseMaskWidth, float *ellipseMaskHeight, bool writeOnModelFile=true)
Set ROI parameters for inspection in label tab.
eErrorType SR_GetOCRTestTextBoxes(OCRTestResult ocrTestResult, SR_OCRTextBox *ocrTextBoxes)
Get SR_OCRTextBox s.
Structure describing features of a OCR object.
Definition: CommonHeaderDLL.h:237
eErrorType SR_SetOCRTestForwardTimeLimit(OCRTestHandle handle, float forwardTimeLimit, bool writeOnModelFile=true)
Set the Forward time limit.
eErrorType SR_GetOCRTestLoadImageTimeInDouble(OCRTestResult ocrTestResult, double *imageLoadingTimeInDouble)
Get the image loading time.
eErrorType SR_SetOCRTestMaxInspectionSize(OCRTestHandle handle, int maxInspectionHeight, int maxInspectionWidth, bool writeOnModelFile=true)
Set OCR's max inspection size.
eErrorType SR_GetOCRTestForwardTimeLimitVariables(OCRTestHandle handle, float *forwardTimeLimit, bool *bIsToUseForwardTimeLimit)
Get the Forward time limit variables.
void * OCRTestHandle
OCR file handler.
Definition: OCRTestDLL.h:52
OCRTestHandle SR_CreateOCRTestHandle(const char *ocrBoxFilePath, const char *ocrTextFilePath)
Create a OCRTestHandle via multi byte char path.
eErrorType SR_GetOCRTestForwardTimeLimit(OCRTestHandle handle, float *forwardTimeLimit)
Get the Forward time limit.