ClassesClassesClassesClasses | | | | Operators

read_data_code_2d_modelread_data_code_2d_modelReadDataCode2dModelread_data_code_2d_modelReadDataCode2dModelReadDataCode2dModel (Operator)

Name

read_data_code_2d_modelread_data_code_2d_modelReadDataCode2dModelread_data_code_2d_modelReadDataCode2dModelReadDataCode2dModel — Read a 2D data code model from a file and create a new model.

Signature

read_data_code_2d_model( : : FileName : DataCodeHandle)

Herror read_data_code_2d_model(const char* FileName, Hlong* DataCodeHandle)

Herror T_read_data_code_2d_model(const Htuple FileName, Htuple* DataCodeHandle)

Herror read_data_code_2d_model(const HTuple& FileName, Hlong* DataCodeHandle)

void HDataCode2D::ReadDataCode2dModel(const HTuple& FileName)

void ReadDataCode2dModel(const HTuple& FileName, HTuple* DataCodeHandle)

void HDataCode2D::HDataCode2D(const HString& FileName)

void HDataCode2D::HDataCode2D(const char* FileName)

void HDataCode2D::ReadDataCode2dModel(const HString& FileName)

void HDataCode2D::ReadDataCode2dModel(const char* FileName)

void HOperatorSetX.ReadDataCode2dModel(
[in] VARIANT FileName, [out] VARIANT* DataCodeHandle)

void HDataCode2DX.ReadDataCode2dModel([in] BSTR FileName)

static void HOperatorSet.ReadDataCode2dModel(HTuple fileName, out HTuple dataCodeHandle)

public HDataCode2D(string fileName)

void HDataCode2D.ReadDataCode2dModel(string fileName)

Description

The operator read_data_code_2d_modelread_data_code_2d_modelReadDataCode2dModelread_data_code_2d_modelReadDataCode2dModelReadDataCode2dModel reads the 2D data code model file FileNameFileNameFileNameFileNameFileNamefileName and creates a new model that is an identical copy of the saved model. The parameter DataCodeHandleDataCodeHandleDataCodeHandleDataCodeHandleDataCodeHandledataCodeHandle returns the handle of the new model. The model file FileNameFileNameFileNameFileNameFileNamefileName must be created by the operator write_data_code_2d_modelwrite_data_code_2d_modelWriteDataCode2dModelwrite_data_code_2d_modelWriteDataCode2dModelWriteDataCode2dModel. The default HALCON file extension for the 2D data code model is 'dcm'.

Parallelization

Parameters

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

Name of the 2D data code model file.

Default value: 'data_code_model.dcm' "data_code_model.dcm" "data_code_model.dcm" "data_code_model.dcm" "data_code_model.dcm" "data_code_model.dcm"

File extension: .dcm

DataCodeHandleDataCodeHandleDataCodeHandleDataCodeHandleDataCodeHandledataCodeHandle (output_control)  datacode_2d HDataCode2D, HTupleHTupleHDataCode2D, HTupleHDataCode2DX, VARIANTHtuple (integer) (IntPtr) (Hlong) (Hlong) (Hlong) (Hlong)

Handle of the created 2D data code model.

Example (HDevelop)

* This example demonstrates how a model that was saved in an earlier
* session can be used again by reading the model file

* Create a model by reading by reading a data code model file
read_data_code_2d_model ('ecc200_trained_model.dcm', DataCodeHandle)
* Read a symbol image
read_image (Image, 'datacode/ecc200/ecc200_cpu_010')
* Read the symbol in the image
find_data_code_2d (Image, SymbolXLDs, DataCodeHandle, [], [], \
                   ResultHandles, DecodedDataStrings)
* Clear the model
clear_data_code_2d_model (DataCodeHandle)

Result

The operator read_data_code_2d_modelread_data_code_2d_modelReadDataCode2dModelread_data_code_2d_modelReadDataCode2dModelReadDataCode2dModel returns the value 2 (H_MSG_TRUE) if the named 2D data code file was found and correctly read. Otherwise, an exception is raised.

Possible Successors

find_data_code_2dfind_data_code_2dFindDataCode2dfind_data_code_2dFindDataCode2dFindDataCode2d

Alternatives

create_data_code_2d_modelcreate_data_code_2d_modelCreateDataCode2dModelcreate_data_code_2d_modelCreateDataCode2dModelCreateDataCode2dModel

See also

write_data_code_2d_modelwrite_data_code_2d_modelWriteDataCode2dModelwrite_data_code_2d_modelWriteDataCode2dModelWriteDataCode2dModel, clear_data_code_2d_modelclear_data_code_2d_modelClearDataCode2dModelclear_data_code_2d_modelClearDataCode2dModelClearDataCode2dModel, clear_all_data_code_2d_modelsclear_all_data_code_2d_modelsClearAllDataCode2dModelsclear_all_data_code_2d_modelsClearAllDataCode2dModelsClearAllDataCode2dModels

Module

Data Code


ClassesClassesClassesClasses | | | | Operators