ClassesClassesClassesClasses | | | | Operators

read_ocvread_ocvReadOcvread_ocvReadOcvReadOcv (Operator)

Name

read_ocvread_ocvReadOcvread_ocvReadOcvReadOcv — Reading an OCV tool from file.

Signature

read_ocv( : : FileName : OCVHandle)

Herror read_ocv(const char* FileName, Hlong* OCVHandle)

Herror T_read_ocv(const Htuple FileName, Htuple* OCVHandle)

Herror read_ocv(const HTuple& FileName, Hlong* OCVHandle)

void HOCV::ReadOcv(const HTuple& FileName)

void ReadOcv(const HTuple& FileName, HTuple* OCVHandle)

void HOCV::HOCV(const HString& FileName)

void HOCV::HOCV(const char* FileName)

void HOCV::ReadOcv(const HString& FileName)

void HOCV::ReadOcv(const char* FileName)

void HOperatorSetX.ReadOcv(
[in] VARIANT FileName, [out] VARIANT* OCVHandle)

void HOCVX.ReadOcv([in] BSTR FileName)

static void HOperatorSet.ReadOcv(HTuple fileName, out HTuple OCVHandle)

public HOCV(string fileName)

void HOCV.ReadOcv(string fileName)

Description

read_ocvread_ocvReadOcvread_ocvReadOcvReadOcv reads an OCV tool from file. The tool will contain the same information that it contained when saving it with write_ocvwrite_ocvWriteOcvwrite_ocvWriteOcvWriteOcv. After reading the tool the training can be completed for those patterns which have not been trained so far. Otherwise a pattern comparison can be applied directly by calling do_ocv_simpledo_ocv_simpleDoOcvSimpledo_ocv_simpleDoOcvSimpleDoOcvSimple.

As extension '.ocv' is used. If this extension is not given with the file name it will be added automatically.

Parallelization

Parameters

FileNameFileNameFileNameFileNameFileNamefileName (input_control)  filename.read HTupleHTupleHTupleVARIANTHtuple (string) (string) (HString) (char*) (BSTR) (char*)

Name of the file which has to be read.

Default value: 'test_ocv' "test_ocv" "test_ocv" "test_ocv" "test_ocv" "test_ocv"

File extension: .ocv

OCVHandleOCVHandleOCVHandleOCVHandleOCVHandleOCVHandle (output_control)  ocv HOCV, HTupleHTupleHOCV, HTupleHOCVX, VARIANTHtuple (integer) (IntPtr) (Hlong) (Hlong) (Hlong) (Hlong)

Handle of read OCV tool.

Example (C++ (HALCON 5.0-10.0))

read_ocv("ocv_file",&ocv_handle);
for (i=0; i<1000; i++)
{
  grab_image_async(&Image,fg_handle,-1);
  reduce_domain(Image,ROI,&Pattern);
  do_ocv_simple(Pattern,ocv_handle,"A",
                "true","true","false","true",10,
                &Quality);
}
close_ocv(ocv_handle);

Result

read_ocvread_ocvReadOcvread_ocvReadOcvReadOcv returns 2 (H_MSG_TRUE), if the file is correct. Otherwise, an exception is raised.

Possible Predecessors

write_ocvwrite_ocvWriteOcvwrite_ocvWriteOcvWriteOcv

Possible Successors

do_ocv_simpledo_ocv_simpleDoOcvSimpledo_ocv_simpleDoOcvSimpleDoOcvSimple, close_ocvclose_ocvCloseOcvclose_ocvCloseOcvCloseOcv

See also

read_ocrread_ocrReadOcrread_ocrReadOcrReadOcr

Module

OCR/OCV


ClassesClassesClassesClasses | | | | Operators