Public Member Functions | |
ScBarcodeScanner * | sc_barcode_scanner_new_with_settings (ScRecognitionContext *context, ScBarcodeScannerSettings const *settings) |
void | sc_barcode_scanner_retain (ScBarcodeScanner *scanner) |
void | sc_barcode_scanner_release (ScBarcodeScanner *scanner) |
ScBarcodeScannerSession * | sc_barcode_scanner_get_session (ScBarcodeScanner *scanner) |
void | sc_barcode_scanner_apply_settings (ScBarcodeScanner *scanner, ScBarcodeScannerSettings const *settings) |
ScBool | sc_barcode_scanner_is_setup_complete (ScBarcodeScanner const *scanner) |
ScBool | sc_barcode_scanner_wait_for_setup_completed (ScBarcodeScanner *scanner) |
Detailed Description
Scans barcodes in images.
The barcode scanner is the main interface for decoding barcodes in images. After constructing a barcode scanner, barcodes are decoded when a frame is processed with sc_recognition_context_process_frame().
Barcode scanner results (decoded and localized barcodes) are available in the "scan session" that can be retrieved by calling sc_barcode_scanner_get_session().
- Since
- 4.6.0
Member Function Documentation
ScBarcodeScanner * sc_barcode_scanner_new_with_settings | ( | ScRecognitionContext * | context, |
ScBarcodeScannerSettings const * | settings | ||
) |
Create a new barcode scanner instance with the given settings.
- Parameters
-
context The recognition context. Must not be null. settings The barcode scanner settings. Must not be null.
- Returns
- a new barcode scanner instance. After use, the instance must be freed with sc_barcode_scanner_release(). NULL is returned, if there is already another barcode scanner associated with this context.
- Since
- 4.6.0
void sc_barcode_scanner_retain | ( | ScBarcodeScanner * | scanner | ) |
Increase reference count of barcode scanner object by one.
- Parameters
-
scanner The barcode scanner object. Must not be null.
- Since
- 4.6.0
void sc_barcode_scanner_release | ( | ScBarcodeScanner * | scanner | ) |
Decrease reference count of barcode scanner by one.
When the reference count drops to zero, the barcode scanner is deallocated.
- Parameters
-
scanner The barcode scanner to release. May be null.
- Since
- 4.6.0
ScBarcodeScannerSession * sc_barcode_scanner_get_session | ( | ScBarcodeScanner * | scanner | ) |
Get the current scanning session.
The scanning session contains the current state of the barcode decoding process, such as the codes that were decoded in the last frame.
- Parameters
-
scanner The barcode scanner object. Must not be null
- Returns
- The session object. The session object is owned by the barcode scanner and is freed automatically when the barcode scanner is released. The returned session object is guaranteed to be non-null.
- Since
- 4.6.0
void sc_barcode_scanner_apply_settings | ( | ScBarcodeScanner * | scanner, |
ScBarcodeScannerSettings const * | settings | ||
) |
Apply new settings.
- Parameters
-
scanner The barcode scanner object. Must not be null. settings The barcode scanner settings object. Must not be null.
- Since
- 4.6.0
ScBool sc_barcode_scanner_is_setup_complete | ( | ScBarcodeScanner const * | scanner | ) |
Checks whether the barcode scanner has completed initialization.
- Parameters
-
scanner The barcode scanner object. Must not be null.
- Returns
- True if setup has completed, false otherwise.
- Since
- 4.6.0
ScBool sc_barcode_scanner_wait_for_setup_completed | ( | ScBarcodeScanner * | scanner | ) |
Block execution until the barcode scanner has completed setup.
- Parameters
-
scanner The barcode scanner object. Must not be null.
- Returns
- True
- Since
- 4.6.0
The documentation for this struct was generated from the following file: