Detailed Description
Contains symbology-specific settings.
Member Function Documentation
ScSymbology sc_symbology_settings_get_symbology | ( | ScSymbologySettings const * | settings | ) |
Get symbology of the symbology settings object.
- Parameters
-
settings The settings object. Must not be null.
- Returns
- The symbology of the symbology settings object.
- Since
- 4.6.0
void sc_symbology_settings_retain | ( | ScSymbologySettings * | settings | ) |
Increase reference count of barcode symbology settings by one.
- Parameters
-
settings The settings object. Must not be null.
- Since
- 4.6.0
void sc_symbology_settings_release | ( | ScSymbologySettings * | settings | ) |
Decrease reference count of barcode symbology settings by one.
When the reference count drops to zero, the symbology settings object is deallocated.
- Parameters
-
settings The settings object. May be null.
- Since
- 4.6.0
ScBool sc_symbology_settings_is_enabled | ( | ScSymbologySettings const * | settings | ) |
Determine whether decoding of this symbology is enabled.
By default decoding of all symbologies is disabled. To enable decoding of a symbology, use sc_symbology_settings_set_enabled(). It is advised to only enable symbologies that are required by the application as every enabled symbology adds processing overhead.
This function only enables decoding of dark codes on bright background. If color-inverted (bright on dark) codes for this symbology are required, enable them using sc_symbology_settings_set_color_inverted_enabled()
- Parameters
-
settings The settings object. Must not be null.
- Returns
- returns true when decoding of codes of this symbology is enabled, false otherwise.
- Since
- 4.6.0
void sc_symbology_settings_set_enabled | ( | ScSymbologySettings * | settings, |
ScBool | enabled | ||
) |
Enable/disable decoding of this symbology.
This function only enables/disables decoding of dark codes on bright background. If color- inverted (bright on dark) codes for this symbology are required, enable them using sc_symbology_settings_set_color_inverted_enabled()
- Parameters
-
settings The settings object. Must not be null. enabled Whether to enable decoding of this symbology.
- Since
- 4.6.0
ScBool sc_symbology_settings_is_color_inverted_enabled | ( | ScSymbologySettings const * | settings | ) |
Determine whether color-inverted decoding of this symbology is enabled.
By default color-inverted decoding of all symbologies is disabled. To enable decoding of use sc_symbology_settings_set_color_inverted_enabled(). It is advised to only enable symbologies that are required by the application as every enabled symbology adds processing overhead.
- Parameters
-
settings The settings object. Must not be null.
- Returns
- True when decoding of codes of this symbology is enabled, false otherwise.
- Since
- 4.6.0
void sc_symbology_settings_set_color_inverted_enabled | ( | ScSymbologySettings * | settings, |
ScBool | enabled | ||
) |
Enable/disable decoding of this symbology.
This function only enables/disables decoding of bright codes on dark background.
- Parameters
-
settings The settings object. Must not be null. enabled Whether to enable decoding of this symbology.
- Since
- 4.6.0
ScChecksums sc_symbology_settings_get_checksums | ( | ScSymbologySettings const * | settings | ) |
Get active optional checksums of this symbology.
This function returns a bit-field of active checksums. When a barcode has been decoded, the checksums returned are evaluated in addition to any mandatory checksum defined by the symbology specification. If any of the checksums matches, the code is returned as recognized, otherwise it is discarded.
Note that most symbologies do not allow any optional checksums.
- Parameters
-
settings the settings object. Must not be null.
- Returns
- bit field of active checksums.
- Since
- 4.6.0
void sc_symbology_settings_set_checksums | ( | ScSymbologySettings * | settings, |
ScChecksums | checksums | ||
) |
Set active optional checksums for this symbology.
This function allows to set additional checksums for this symbology.
- Parameters
-
settings The settings object. Must not be null. checksums Bit-wise combination of ScChecksum values.
- Since
- 4.6.0
ScBool sc_symbology_settings_is_extension_enabled | ( | ScSymbologySettings const * | settings, |
char const * | extension | ||
) |
Determine whether a certain extension is enabled for the symbology.
Extensions are custom features that are only supported by a small number of symbologies. For a list of supported extensions, consult Change the symbologies' default properties.
- Parameters
-
settings The settings object. Must not be null. extension Name of the extension.
- Returns
- True if the extension is enabled, false if not.
See Change the symbologies' default properties for a list of all available extensions.
- Since
- 4.6.0
void sc_symbology_settings_set_extension_enabled | ( | ScSymbologySettings * | settings, |
char const * | extension, | ||
ScBool | enabled | ||
) |
Activate/Deactivate a custom extension for the symbology.
Extensions are custom features that are only supported by a small number of symbologies. For a list of supported extensions, consult Change the symbologies' default properties.
- Parameters
-
settings The settings object. Must not be null. extension Name of the extension. enabled Whether the extension should be enabled/disabled.
- Since
- 4.6.0
char ** sc_symbology_settings_get_enabled_extensions | ( | ScSymbologySettings * | settings | ) |
Get all enabled extensions for this symbology.
- Parameters
-
settings The settings object. Must not be null.
- Returns
- A null-terminated array containing the enabled extensions. The array as well as the individual strings must be freed with sc_free once they are not used anymore.
- Since
- 4.16.0
void sc_symbology_settings_set_active_symbol_counts | ( | ScSymbologySettings * | settings, |
uint16_t const * | active_counts, | ||
uint16_t | num_counts | ||
) |
This function allows to control the length of barcodes to be decoded.
Call this function to enable decoding of long codes which can not be decoded with the default settings, or to optimize decoder performance for codes of certain lengths. This is useful when it is known that the application only requires scanning of particular barcode lengths.
The mapping from characters to symbols is symbology-specific. For some symbologies, the start and end characters are included, others include checksums characters in the symbol counts.
The active symbol count setting is ignored for fixed-size barcodes (the EAN and UPC family of codes) as well as 2d codes. For other symbologies, see Change the symbologies' default properties for a list of supported symbol counts, and Calculating Symbol Counts for Variable-Length Symbologies .
Symbol counts that are outside of the supported symbol count range are ignored.
- Parameters
-
settings The settings object. Must not be null. active_counts Pointer to a non-empty array of active counts. num_counts The number of elements in active_counts.
- Since
- 4.6.0
void sc_symbology_settings_get_active_symbol_counts | ( | ScSymbologySettings * | settings, |
uint16_t ** | active_counts, | ||
uint16_t * | num_counts | ||
) |
Retrieve the current active symbol counts of this symbology.
For a description of what active symbol counts are, refer to sc_symbology_settings_set_active_symbol_counts()
- Parameters
-
settings The settings object. Must not be null. active_counts Pointer to array of active counts. When the function returns, the array contains the active symbol counts for this symbology. After use, the array must be freed with sc_free. Null may be passed for this argument in which case only num_counts will be set to the length of the active_counts array. num_counts The number of elements in active_counts. When the function returns, num_counts is set to the number of elements in active_counts. Must not be null.
- Since
- 4.6.0
The documentation for this struct was generated from the following file: