Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
2bda812
C Wrapper Barcode Live Example
Aug 5, 2025
6086e0d
Use goto in c wrapper example
Aug 6, 2025
51420c7
Readme files c wrapper
Aug 6, 2025
649cd88
Add tensorrt support
Aug 6, 2025
a13b192
Improve FindScanbotSDK.cmake
Aug 6, 2025
e021d63
refactor structure of java example. added new snippets
yurii-scanbot Aug 6, 2025
be1b02b
refactor structure of python example
yurii-scanbot Aug 6, 2025
4ae7a0a
merge c wrapper example
yurii-scanbot Aug 6, 2025
ed2aceb
fixed merge conflics c barcode examples
yurii-scanbot Aug 7, 2025
a4573e2
restructure project and add scan/analyze/classify/parse snippets with…
yurii-scanbot Aug 18, 2025
b88612a
add snippets for nodejs wrapper
yurii-scanbot Aug 21, 2025
5afb93a
Merge pull request #20 from doo/yk/snippets_nodejs
yurii-scanbot Aug 21, 2025
9aed4c2
replace magic constants
yurii-scanbot Aug 21, 2025
14765af
remove function declarations from headers that aren't in use
yurii-scanbot Aug 21, 2025
a155f75
refactor main.c, for early outs always goto cleanup
yurii-scanbot Aug 21, 2025
984e928
refactor snippets cleanups and unnecessary condition under default cr…
yurii-scanbot Aug 21, 2025
01939df
refactored analyse sumcommand and floatin license snippets with clear…
yurii-scanbot Aug 22, 2025
c129240
added optional param for --license in cli
yurii-scanbot Aug 22, 2025
fbc934d
updated nodejs snippets with better way to dispose unmanaged resource…
yurii-scanbot Aug 22, 2025
cd6045b
added --license key flag from cli to java and python examples
yurii-scanbot Aug 22, 2025
70ca861
rename mrz parser snippet java
yurii-scanbot Aug 22, 2025
308eaea
separate live scanners snippets
yurii-scanbot Aug 25, 2025
5c8bd8b
refactor java snippets, improve comments
yurii-scanbot Aug 26, 2025
499dcc4
removed unnecessary license checks inside of code snippets and remove…
yurii-scanbot Aug 26, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
.DS_Store
statistics.dat

examples/c/build/*
examples/nodejs/node_modules
6 changes: 5 additions & 1 deletion examples/c/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,8 @@ set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake/")
set(SCANBOTSDK_DIR "${CMAKE_CURRENT_BINARY_DIR}/scanbotsdk")
find_package(ScanbotSDK REQUIRED)

add_subdirectory(barcode)
file(GLOB_RECURSE SOURCE_FILES CONFIGURE_DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/src/*.c)
add_executable(scanbotsdk_example ${SOURCE_FILES})
target_include_directories(scanbotsdk_example PRIVATE include)
target_link_libraries(scanbotsdk_example PRIVATE scanbotsdk)

7 changes: 0 additions & 7 deletions examples/c/barcode/minimal/CMakeLists.txt

This file was deleted.

8 changes: 0 additions & 8 deletions examples/c/barcode/minimal/README.md

This file was deleted.

129 changes: 0 additions & 129 deletions examples/c/barcode/minimal/main.c

This file was deleted.

8 changes: 8 additions & 0 deletions examples/c/include/snippets/barcode/detect_barcode.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#ifndef DETECT_BARCODE_H
#define DETECT_BARCODE_H

#include <ScanbotSDK.h>

scanbotsdk_error_code_t detect_barcode(scanbotsdk_image_t *image);

#endif
8 changes: 8 additions & 0 deletions examples/c/include/snippets/barcode/parse_barcode_document.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#ifndef PARSE_BARCODE_DOCUMENT_H
#define PARSE_BARCODE_DOCUMENT_H

#include <ScanbotSDK.h>

scanbotsdk_error_code_t parse_barcode_document(const char* raw_string);

#endif
8 changes: 8 additions & 0 deletions examples/c/include/snippets/datacapture/check_scanner.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#ifndef CHECK_SCANNER_H
#define CHECK_SCANNER_H

#include <ScanbotSDK.h>

scanbotsdk_error_code_t detect_check(scanbotsdk_image_t *image);

#endif
8 changes: 8 additions & 0 deletions examples/c/include/snippets/datacapture/credit_card_scanner.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#ifndef CREDIT_CARD_SCANNER_H
#define CREDIT_CARD_SCANNER_H

#include <ScanbotSDK.h>

scanbotsdk_error_code_t detect_credit_card(scanbotsdk_image_t *image);

#endif
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#ifndef DDE_EXTRACTOR_H
#define DDE_EXTRACTOR_H

#include <ScanbotSDK.h>

scanbotsdk_error_code_t extract_document_data(scanbotsdk_image_t *image);

#endif
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#ifndef MEDICAL_CERTIFICATE_SCANNER_H
#define MEDICAL_CERTIFICATE_SCANNER_H

#include <ScanbotSDK.h>

scanbotsdk_error_code_t detect_medical_certificate(scanbotsdk_image_t *image);

#endif
8 changes: 8 additions & 0 deletions examples/c/include/snippets/datacapture/mrz_parser.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#ifndef MRZ_PARSER_H
#define MRZ_PARSER_H

#include <ScanbotSDK.h>

scanbotsdk_error_code_t parse_mrz(const char* text);

#endif
8 changes: 8 additions & 0 deletions examples/c/include/snippets/datacapture/mrz_scanner.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#ifndef MRZ_SCANNER_H
#define MRZ_SCANNER_H

#include <ScanbotSDK.h>

scanbotsdk_error_code_t detect_mrz(scanbotsdk_image_t *image);

#endif
8 changes: 8 additions & 0 deletions examples/c/include/snippets/datacapture/ocr.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#ifndef OCR_SCANNER_H
#define OCR_SCANNER_H

#include <ScanbotSDK.h>

scanbotsdk_error_code_t ocr_run(scanbotsdk_image_t *image);

#endif
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#ifndef TEXT_PATTERN_SCANNER_H
#define TEXT_PATTERN_SCANNER_H

#include <ScanbotSDK.h>

scanbotsdk_error_code_t detect_text_pattern(scanbotsdk_image_t *image);

#endif
8 changes: 8 additions & 0 deletions examples/c/include/snippets/datacapture/vin_scanner.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#ifndef VIN_SCANNER_H
#define VIN_SCANNER_H

#include <ScanbotSDK.h>

scanbotsdk_error_code_t detect_vin(scanbotsdk_image_t *image);

#endif
8 changes: 8 additions & 0 deletions examples/c/include/snippets/document/analyse_multi_page.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#ifndef ANALYSE_MULTI_PAGE_H
#define ANALYSE_MULTI_PAGE_H

#include <ScanbotSDK.h>

scanbotsdk_error_code_t analyse_multi_page(char* path);

#endif
8 changes: 8 additions & 0 deletions examples/c/include/snippets/document/crop_and_analyse.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#ifndef CROP_AND_ANALYSE_H
#define CROP_AND_ANALYSE_H

#include <ScanbotSDK.h>

scanbotsdk_error_code_t crop_and_analyse(scanbotsdk_image_t *image, char* save_path);

#endif
8 changes: 8 additions & 0 deletions examples/c/include/snippets/document/detect_document.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#ifndef DETECT_DOCUMENT_H
#define DETECT_DOCUMENT_H

#include <ScanbotSDK.h>

scanbotsdk_error_code_t detect_document(scanbotsdk_image_t *image);

#endif
8 changes: 8 additions & 0 deletions examples/c/include/snippets/document/document_classifier.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#ifndef DOCUMENT_CLASSIFIER_H
#define DOCUMENT_CLASSIFIER_H

#include <ScanbotSDK.h>

scanbotsdk_error_code_t classify_document(scanbotsdk_image_t *image);

#endif
9 changes: 9 additions & 0 deletions examples/c/include/snippets/license/floating_license.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#ifndef FLOATING_LICENSE_H
#define FLOATING_LICENSE_H

#include <ScanbotSDK.h>

void init_with_floating_license();
char* license_status_str(scanbotsdk_license_status_t s);

#endif
9 changes: 9 additions & 0 deletions examples/c/include/snippets/live/live_barcode.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#ifndef LIVE_BARCODE_H
#define LIVE_BARCODE_H

#include <ScanbotSDK.h>
#include <stdbool.h>

scanbotsdk_error_code_t run_live_barcode_scanner(const char *mock_frame_path, bool use_tensor_rt);

#endif
16 changes: 16 additions & 0 deletions examples/c/include/utils/utils.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#ifndef UTILS_H
#define UTILS_H

#include <ScanbotSDK.h>

const char *error_message(scanbotsdk_error_code_t ec);

scanbotsdk_error_code_t load_image_from_path(const char *path, scanbotsdk_image_t **out_image);

scanbotsdk_error_code_t print_generic_document_fields(scanbotsdk_generic_document_t *doc);

void print_usage(const char *prog);

char* get_flag(int argc, char *argv[], const char *flag);

#endif
Loading