ClassesClasses | | Operators

set_data_code_2d_paramT_set_data_code_2d_paramSetDataCode2dParamSetDataCode2dParam (Operator)

Name

set_data_code_2d_paramT_set_data_code_2d_paramSetDataCode2dParamSetDataCode2dParam — Set selected parameters of the 2D data code model.

Signature

set_data_code_2d_param( : : DataCodeHandle, GenParamName, GenParamValue : )

Herror T_set_data_code_2d_param(const Htuple DataCodeHandle, const Htuple GenParamName, const Htuple GenParamValue)

void SetDataCode2dParam(const HTuple& DataCodeHandle, const HTuple& GenParamName, const HTuple& GenParamValue)

void HDataCode2D::SetDataCode2dParam(const HTuple& GenParamName, const HTuple& GenParamValue) const

void HDataCode2D::SetDataCode2dParam(const HString& GenParamName, const HString& GenParamValue) const

void HDataCode2D::SetDataCode2dParam(const char* GenParamName, const char* GenParamValue) const

static void HOperatorSet.SetDataCode2dParam(HTuple dataCodeHandle, HTuple genParamName, HTuple genParamValue)

void HDataCode2D.SetDataCode2dParam(HTuple genParamName, HTuple genParamValue)

void HDataCode2D.SetDataCode2dParam(string genParamName, string genParamValue)

Description

The operator set_data_code_2d_paramset_data_code_2d_paramSetDataCode2dParamSetDataCode2dParamSetDataCode2dParam is used to set or change the different parameters of a 2D data code model in order to adapt the model to a particular symbol appearance. All parameters can also be set while creating a 2D data code model with create_data_code_2d_modelcreate_data_code_2d_modelCreateDataCode2dModelCreateDataCode2dModelCreateDataCode2dModel. The current configuration of the data code model can be queried with get_data_code_2d_paramget_data_code_2d_paramGetDataCode2dParamGetDataCode2dParamGetDataCode2dParam. A list with the names of all parameters that can be set for the given 2D data code type is returned by query_data_code_2d_paramsquery_data_code_2d_paramsQueryDataCode2dParamsQueryDataCode2dParamsQueryDataCode2dParams.

For an explanation of the concept of the 2D data code reader see the introduction of chapter Identification / Data Code.

Note that the symbol structure of GS1 DataMatrix, GS1 QR Code, and GS1 Aztec is identical to the structure of ECC 200, QR Code, and Aztec Code, respectively. Therefore, all symbology specific parameters applying to ECC 200, QR Code, or Aztec Code apply to their corresponding GS1 variant as well. In the following, the explicit enumeration of the parameters for any particular GS1 code is omitted for sake of readability. Instead, the relevant parameters names are to be inferred from the parameters for the corresponding non-GS1 code type or can be explicitly queried by query_data_code_2d_paramsquery_data_code_2d_paramsQueryDataCode2dParamsQueryDataCode2dParamsQueryDataCode2dParams with parameter 'set_model_params'"set_model_params""set_model_params""set_model_params""set_model_params".

The following overview lists the different generic parameters with the respective value ranges and default values in standard mode ('standard_recognition'"standard_recognition""standard_recognition""standard_recognition""standard_recognition"). If the default values in enhanced mode ('enhanced_recognition'"enhanced_recognition""enhanced_recognition""enhanced_recognition""enhanced_recognition") differ from those in the standard mode, they are listed additionally. The same holds, if the default values in the maximum mode 'maximum_recognition'"maximum_recognition""maximum_recognition""maximum_recognition""maximum_recognition" differ from those in the enhanced mode:

Basic default settings:

Size and shape of the symbol:

Appearance of the modules in the image:

General model behavior:

When setting the model parameters, attention should be payed especially to the following issues:

Execution Information

This operator modifies the state of the following input parameter:

The value of this parameter may not be shared across multiple threads without external synchronization.

Parameters

DataCodeHandleDataCodeHandleDataCodeHandleDataCodeHandledataCodeHandle (input_control, state is modified)  datacode_2d HDataCode2D, HTupleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)

Handle of the 2D data code model.

GenParamNameGenParamNameGenParamNameGenParamNamegenParamName (input_control)  attribute.name(-array) HTupleHTupleHtuple (string) (string) (HString) (char*)

Names of the generic parameters that shall be adjusted for the 2D data code.

Default value: 'polarity' "polarity" "polarity" "polarity" "polarity"

List of values: 'abort'"abort""abort""abort""abort", 'additional_levels'"additional_levels""additional_levels""additional_levels""additional_levels", 'contrast_min'"contrast_min""contrast_min""contrast_min""contrast_min", 'contrast_tolerance'"contrast_tolerance""contrast_tolerance""contrast_tolerance""contrast_tolerance", 'decoding_scheme'"decoding_scheme""decoding_scheme""decoding_scheme""decoding_scheme", 'default_parameters'"default_parameters""default_parameters""default_parameters""default_parameters", 'discard_undecoded_candidates'"discard_undecoded_candidates""discard_undecoded_candidates""discard_undecoded_candidates""discard_undecoded_candidates", 'finder_pattern_tolerance'"finder_pattern_tolerance""finder_pattern_tolerance""finder_pattern_tolerance""finder_pattern_tolerance", 'format'"format""format""format""format", 'mirrored'"mirrored""mirrored""mirrored""mirrored", 'model_type'"model_type""model_type""model_type""model_type", 'module_aspect'"module_aspect""module_aspect""module_aspect""module_aspect", 'module_aspect_max'"module_aspect_max""module_aspect_max""module_aspect_max""module_aspect_max", 'module_aspect_min'"module_aspect_min""module_aspect_min""module_aspect_min""module_aspect_min", 'module_gap'"module_gap""module_gap""module_gap""module_gap", 'module_gap_max'"module_gap_max""module_gap_max""module_gap_max""module_gap_max", 'module_gap_min'"module_gap_min""module_gap_min""module_gap_min""module_gap_min", 'module_grid'"module_grid""module_grid""module_grid""module_grid", 'module_size'"module_size""module_size""module_size""module_size", 'module_size_max'"module_size_max""module_size_max""module_size_max""module_size_max", 'module_size_min'"module_size_min""module_size_min""module_size_min""module_size_min", 'module_width'"module_width""module_width""module_width""module_width", 'module_width_max'"module_width_max""module_width_max""module_width_max""module_width_max", 'module_width_min'"module_width_min""module_width_min""module_width_min""module_width_min", 'persistence'"persistence""persistence""persistence""persistence", 'polarity'"polarity""polarity""polarity""polarity", 'position_pattern_min'"position_pattern_min""position_pattern_min""position_pattern_min""position_pattern_min", 'quality_isoiec15415_aperture_size'"quality_isoiec15415_aperture_size""quality_isoiec15415_aperture_size""quality_isoiec15415_aperture_size""quality_isoiec15415_aperture_size", 'slant_max'"slant_max""slant_max""slant_max""slant_max", 'small_modules_robustness'"small_modules_robustness""small_modules_robustness""small_modules_robustness""small_modules_robustness", 'strict_model'"strict_model""strict_model""strict_model""strict_model", 'strict_quiet_zone'"strict_quiet_zone""strict_quiet_zone""strict_quiet_zone""strict_quiet_zone", 'symbol_cols'"symbol_cols""symbol_cols""symbol_cols""symbol_cols", 'symbol_cols_max'"symbol_cols_max""symbol_cols_max""symbol_cols_max""symbol_cols_max", 'symbol_cols_min'"symbol_cols_min""symbol_cols_min""symbol_cols_min""symbol_cols_min", 'symbol_rows'"symbol_rows""symbol_rows""symbol_rows""symbol_rows", 'symbol_rows_max'"symbol_rows_max""symbol_rows_max""symbol_rows_max""symbol_rows_max", 'symbol_rows_min'"symbol_rows_min""symbol_rows_min""symbol_rows_min""symbol_rows_min", 'symbol_shape'"symbol_shape""symbol_shape""symbol_shape""symbol_shape", 'symbol_size'"symbol_size""symbol_size""symbol_size""symbol_size", 'symbol_size_max'"symbol_size_max""symbol_size_max""symbol_size_max""symbol_size_max", 'symbol_size_min'"symbol_size_min""symbol_size_min""symbol_size_min""symbol_size_min", 'timeout'"timeout""timeout""timeout""timeout", 'trained'"trained""trained""trained""trained", 'version'"version""version""version""version", 'version_max'"version_max""version_max""version_max""version_max", 'version_min'"version_min""version_min""version_min""version_min"

GenParamValueGenParamValueGenParamValueGenParamValuegenParamValue (input_control)  attribute.value(-array) HTupleHTupleHtuple (string / integer / real) (string / int / long / double) (HString / Hlong / double) (char* / Hlong / double)

Values of the generic parameters that are adjusted for the 2D data code.

Default value: 'light_on_dark' "light_on_dark" "light_on_dark" "light_on_dark" "light_on_dark"

Suggested values: 'standard_recognition'"standard_recognition""standard_recognition""standard_recognition""standard_recognition", 'enhanced_recognition'"enhanced_recognition""enhanced_recognition""enhanced_recognition""enhanced_recognition", 'maximum_recognition'"maximum_recognition""maximum_recognition""maximum_recognition""maximum_recognition", 'yes'"yes""yes""yes""yes", 'no'"no""no""no""no", 'any'"any""any""any""any", 'dark_on_light'"dark_on_light""dark_on_light""dark_on_light""dark_on_light", 'light_on_dark'"light_on_dark""light_on_dark""light_on_dark""light_on_dark", 'square'"square""square""square""square", 'rectangle'"rectangle""rectangle""rectangle""rectangle", 'small'"small""small""small""small", 'big'"big""big""big""big", 'fixed'"fixed""fixed""fixed""fixed", 'variable'"variable""variable""variable""variable", 'low'"low""low""low""low", 'high'"high""high""high""high", 0, 1, 2, 3, 4, 5, 6, 7, 8, 10, 30, 50, 70, 90, 12, 14, 16, 18, 20, 22, 24, 26, 32, 36, 40, 44, 48, 52, 64, 72, 80, 88, 96, 104, 120, 132, 144

Example (HDevelop)

* This examples shows how a model can be adapted to a specific symbol if
* the symbol parameters are known

* Create a model for reading Data matrix ECC 200 codes
create_data_code_2d_model ('Data Matrix ECC 200', [], [], DataCodeHandle)
* Restrict the model by setting the module size
set_data_code_2d_param (DataCodeHandle, \
                        ['module_size_min','module_size_max'], [4,7])
* Change the polarity setting of the model from 'dark_on_light' to
* 'light_on_dark' and, at the same time, specify a new minimum contrast
set_data_code_2d_param (DataCodeHandle, ['polarity','contrast_min'], \
                        ['light_on_dark',10])

* Read an 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 set_data_code_2d_paramset_data_code_2d_paramSetDataCode2dParamSetDataCode2dParamSetDataCode2dParam returns the value 2 (H_MSG_TRUE) if the given parameters are correct. Otherwise, an exception is raised.

Possible Predecessors

create_data_code_2d_modelcreate_data_code_2d_modelCreateDataCode2dModelCreateDataCode2dModelCreateDataCode2dModel, read_data_code_2d_modelread_data_code_2d_modelReadDataCode2dModelReadDataCode2dModelReadDataCode2dModel

Possible Successors

get_data_code_2d_paramget_data_code_2d_paramGetDataCode2dParamGetDataCode2dParamGetDataCode2dParam, find_data_code_2dfind_data_code_2dFindDataCode2dFindDataCode2dFindDataCode2d, write_data_code_2d_modelwrite_data_code_2d_modelWriteDataCode2dModelWriteDataCode2dModelWriteDataCode2dModel

Alternatives

read_data_code_2d_modelread_data_code_2d_modelReadDataCode2dModelReadDataCode2dModelReadDataCode2dModel

See also

query_data_code_2d_paramsquery_data_code_2d_paramsQueryDataCode2dParamsQueryDataCode2dParamsQueryDataCode2dParams, get_data_code_2d_paramget_data_code_2d_paramGetDataCode2dParamGetDataCode2dParamGetDataCode2dParam, get_data_code_2d_resultsget_data_code_2d_resultsGetDataCode2dResultsGetDataCode2dResultsGetDataCode2dResults, get_data_code_2d_objectsget_data_code_2d_objectsGetDataCode2dObjectsGetDataCode2dObjectsGetDataCode2dObjects

Module

Data Code


ClassesClasses | | Operators