Scanbot SDK
Loading...
Searching...
No Matches
Scanbot C SDK Document quality analyzer

Typedefs

typedef struct scanbotsdk_document_quality_analyzer_t scanbotsdk_document_quality_analyzer_t
 scanbotsdk_document_quality_analyzer_t class
 
typedef enum scanbotsdk_document_quality_t scanbotsdk_document_quality_t
 scanbotsdk_document_quality_t enum
 
typedef enum scanbotsdk_document_quality_assessment_t scanbotsdk_document_quality_assessment_t
 scanbotsdk_document_quality_assessment_t enum
 
typedef struct scanbotsdk_document_quality_threshold_t scanbotsdk_document_quality_threshold_t
 scanbotsdk_document_quality_threshold_t class
 
typedef struct scanbotsdk_process_by_tile_configuration_t scanbotsdk_process_by_tile_configuration_t
 scanbotsdk_process_by_tile_configuration_t class
 
typedef enum scanbotsdk_document_quality_analyzer_compatibility_mode_t scanbotsdk_document_quality_analyzer_compatibility_mode_t
 scanbotsdk_document_quality_analyzer_compatibility_mode_t enum
 
typedef struct scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t
 scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t class
 
typedef struct scanbotsdk_document_quality_analyzer_configuration_t scanbotsdk_document_quality_analyzer_configuration_t
 scanbotsdk_document_quality_analyzer_configuration_t class
 
typedef struct scanbotsdk_character_level_annotation_t scanbotsdk_character_level_annotation_t
 scanbotsdk_character_level_annotation_t class
 
typedef struct scanbotsdk_character_level_annotations_t scanbotsdk_character_level_annotations_t
 scanbotsdk_character_level_annotations_t class
 
typedef struct scanbotsdk_document_quality_analyzer_training_data_t scanbotsdk_document_quality_analyzer_training_data_t
 scanbotsdk_document_quality_analyzer_training_data_t class
 
typedef struct scanbotsdk_document_quality_analyzer_result_t scanbotsdk_document_quality_analyzer_result_t
 scanbotsdk_document_quality_analyzer_result_t class
 

Enumerations

enum  scanbotsdk_document_quality_t {
  SCANBOTSDK_DOCUMENT_QUALITY_VERY_POOR = 0 ,
  SCANBOTSDK_DOCUMENT_QUALITY_POOR = 1 ,
  SCANBOTSDK_DOCUMENT_QUALITY_REASONABLE = 2 ,
  SCANBOTSDK_DOCUMENT_QUALITY_GOOD = 3 ,
  SCANBOTSDK_DOCUMENT_QUALITY_EXCELLENT = 4
}
 scanbotsdk_document_quality_t enum More...
 
enum  scanbotsdk_document_quality_assessment_t {
  SCANBOTSDK_DOCUMENT_QUALITY_ASSESSMENT_ACCEPTABLE = 0 ,
  SCANBOTSDK_DOCUMENT_QUALITY_ASSESSMENT_UNACCEPTABLE = 1 ,
  SCANBOTSDK_DOCUMENT_QUALITY_ASSESSMENT_UNCERTAIN = 2
}
 scanbotsdk_document_quality_assessment_t enum More...
 
enum  scanbotsdk_document_quality_analyzer_compatibility_mode_t { SCANBOTSDK_DOCUMENT_QUALITY_ANALYZER_COMPATIBILITY_MODE_V8 = 0 }
 scanbotsdk_document_quality_analyzer_compatibility_mode_t enum More...
 

Functions

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_create (scanbotsdk_document_quality_analyzer_configuration_t *configuration, scanbotsdk_document_quality_analyzer_t **result)
 Creates a new instance of scanbotsdk_document_quality_analyzer with given params and stores it in the location specified by the last argument.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_free (scanbotsdk_document_quality_analyzer_t *self)
 Frees the memory allocated for the instance of scanbotsdk_document_quality_analyzer_t. If null is passed, the function does nothing.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_run (scanbotsdk_document_quality_analyzer_t *self, scanbotsdk_image_t *image, scanbotsdk_document_quality_analyzer_result_t **result)
 analyze document quality of the given image.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_t_to_string (scanbotsdk_document_quality_t value, const char **result)
 Returns the string representation of the given scanbotsdk_document_quality_t value.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_assessment_t_to_string (scanbotsdk_document_quality_assessment_t value, const char **result)
 Returns the string representation of the given scanbotsdk_document_quality_assessment_t value.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_threshold_create (double symbol_quality, double symbol_ratio, scanbotsdk_document_quality_threshold_t **result)
 Creates a new instance of scanbotsdk_document_quality_threshold with given params and stores it in the location specified by the last argument.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_threshold_free (scanbotsdk_document_quality_threshold_t *object)
 Frees the memory allocated for the instance of scanbotsdk_document_quality_threshold_t. If null is passed, the function does nothing.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_threshold_get_symbol_quality (scanbotsdk_document_quality_threshold_t *self, double *symbol_quality)
 Returns value of symbol_quality field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_threshold_get_symbol_ratio (scanbotsdk_document_quality_threshold_t *self, double *symbol_ratio)
 Returns value of symbol_ratio field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_create (bool enabled, double min_processed_fraction, double max_processed_fraction, int min_number_of_required_symbols, int tile_size, scanbotsdk_process_by_tile_configuration_t **result)
 Creates a new instance of scanbotsdk_process_by_tile_configuration with given params and stores it in the location specified by the last argument.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_create_with_defaults (scanbotsdk_process_by_tile_configuration_t **result)
 Creates a new instance of scanbotsdk_process_by_tile_configuration_t with given required params and stores it in the location specified by the last argument.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_free (scanbotsdk_process_by_tile_configuration_t *object)
 Frees the memory allocated for the instance of scanbotsdk_process_by_tile_configuration_t. If null is passed, the function does nothing.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_get_enabled (scanbotsdk_process_by_tile_configuration_t *self, bool *enabled)
 Returns value of enabled field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_set_enabled (scanbotsdk_process_by_tile_configuration_t *self, bool enabled)
 Sets value of enabled field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_get_min_processed_fraction (scanbotsdk_process_by_tile_configuration_t *self, double *min_processed_fraction)
 Returns value of min_processed_fraction field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_set_min_processed_fraction (scanbotsdk_process_by_tile_configuration_t *self, double min_processed_fraction)
 Sets value of min_processed_fraction field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_get_max_processed_fraction (scanbotsdk_process_by_tile_configuration_t *self, double *max_processed_fraction)
 Returns value of max_processed_fraction field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_set_max_processed_fraction (scanbotsdk_process_by_tile_configuration_t *self, double max_processed_fraction)
 Sets value of max_processed_fraction field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_get_min_number_of_required_symbols (scanbotsdk_process_by_tile_configuration_t *self, int *min_number_of_required_symbols)
 Returns value of min_number_of_required_symbols field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_set_min_number_of_required_symbols (scanbotsdk_process_by_tile_configuration_t *self, int min_number_of_required_symbols)
 Sets value of min_number_of_required_symbols field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_get_tile_size (scanbotsdk_process_by_tile_configuration_t *self, int *tile_size)
 Returns value of tile_size field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_set_tile_size (scanbotsdk_process_by_tile_configuration_t *self, int tile_size)
 Sets value of tile_size field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_t_to_string (scanbotsdk_document_quality_analyzer_compatibility_mode_t value, const char **result)
 Returns the string representation of the given scanbotsdk_document_quality_analyzer_compatibility_mode_t value.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_create (scanbotsdk_document_quality_analyzer_compatibility_mode_t mode, scanbotsdk_document_quality_t minimum_acceptable_quality, scanbotsdk_document_quality_t minimum_uncertain_quality, bool inspect_small_text, scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t **result)
 Creates a new instance of scanbotsdk_document_quality_analyzer_compatibility_mode_configuration with given params and stores it in the location specified by the last argument.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_create_with_defaults (scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t **result)
 Creates a new instance of scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t with given required params and stores it in the location specified by the last argument.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_free (scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t *object)
 Frees the memory allocated for the instance of scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t. If null is passed, the function does nothing.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_get_mode (scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t *self, scanbotsdk_document_quality_analyzer_compatibility_mode_t *mode)
 Returns value of mode field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_get_minimum_acceptable_quality (scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t *self, scanbotsdk_document_quality_t *minimum_acceptable_quality)
 Returns value of minimum_acceptable_quality field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_set_minimum_acceptable_quality (scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t *self, scanbotsdk_document_quality_t minimum_acceptable_quality)
 Sets value of minimum_acceptable_quality field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_get_minimum_uncertain_quality (scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t *self, scanbotsdk_document_quality_t *minimum_uncertain_quality)
 Returns value of minimum_uncertain_quality field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_set_minimum_uncertain_quality (scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t *self, scanbotsdk_document_quality_t minimum_uncertain_quality)
 Sets value of minimum_uncertain_quality field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_get_inspect_small_text (scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t *self, bool *inspect_small_text)
 Returns value of inspect_small_text field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_set_inspect_small_text (scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t *self, bool inspect_small_text)
 Sets value of inspect_small_text field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_create (const char *quality_analysis_model, double quality_acceptable_uncertain_threshold, double quality_unacceptable_uncertain_threshold, scanbotsdk_document_quality_threshold_t **quality_level_thresholds, size_t quality_level_thresholds_size, scanbotsdk_document_quality_t *quality_level_indices, size_t quality_level_indices_size, double *input_scales, size_t input_scales_size, double input_scale_threshold_to_process_entire_image, int max_image_size, int min_estimated_number_of_symbols_for_document, scanbotsdk_process_by_tile_configuration_t *process_by_tile_configuration, double min_required_orientation_confidence, bool return_quality_heatmap, scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t *compatibility_mode, scanbotsdk_document_quality_analyzer_configuration_t **result)
 Creates a new instance of scanbotsdk_document_quality_analyzer_configuration with given params and stores it in the location specified by the last argument.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_create_with_defaults (scanbotsdk_document_quality_analyzer_configuration_t **result)
 Creates a new instance of scanbotsdk_document_quality_analyzer_configuration_t with given required params and stores it in the location specified by the last argument.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_free (scanbotsdk_document_quality_analyzer_configuration_t *object)
 Frees the memory allocated for the instance of scanbotsdk_document_quality_analyzer_configuration_t. If null is passed, the function does nothing.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_quality_analysis_model (scanbotsdk_document_quality_analyzer_configuration_t *self, const char **quality_analysis_model)
 Returns value of quality_analysis_model field of the given object. The returned pointers do NOT own the underlying object, caller must not free them.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_quality_analysis_model (scanbotsdk_document_quality_analyzer_configuration_t *self, const char *quality_analysis_model)
 Sets value of quality_analysis_model field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_quality_acceptable_uncertain_threshold (scanbotsdk_document_quality_analyzer_configuration_t *self, double *quality_acceptable_uncertain_threshold)
 Returns value of quality_acceptable_uncertain_threshold field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_quality_acceptable_uncertain_threshold (scanbotsdk_document_quality_analyzer_configuration_t *self, double quality_acceptable_uncertain_threshold)
 Sets value of quality_acceptable_uncertain_threshold field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_quality_unacceptable_uncertain_threshold (scanbotsdk_document_quality_analyzer_configuration_t *self, double *quality_unacceptable_uncertain_threshold)
 Returns value of quality_unacceptable_uncertain_threshold field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_quality_unacceptable_uncertain_threshold (scanbotsdk_document_quality_analyzer_configuration_t *self, double quality_unacceptable_uncertain_threshold)
 Sets value of quality_unacceptable_uncertain_threshold field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_quality_level_thresholds (scanbotsdk_document_quality_analyzer_configuration_t *self, scanbotsdk_document_quality_threshold_t **quality_level_thresholds, size_t size)
 Returns value of quality_level_thresholds field of the given object. The returned pointers do NOT own the underlying object, caller must not free them.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_quality_level_thresholds_size (scanbotsdk_document_quality_analyzer_configuration_t *self, size_t *size)
 Returns size of quality_level_thresholds array.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_quality_level_thresholds (scanbotsdk_document_quality_analyzer_configuration_t *self, scanbotsdk_document_quality_threshold_t **quality_level_thresholds, size_t quality_level_thresholds_size)
 Sets value of quality_level_thresholds field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_quality_level_indices (scanbotsdk_document_quality_analyzer_configuration_t *self, scanbotsdk_document_quality_t **quality_level_indices)
 Returns value of quality_level_indices field of the given object. The returned value is direct view into memory, no pre-allocations needed.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_quality_level_indices_size (scanbotsdk_document_quality_analyzer_configuration_t *self, size_t *size)
 Returns size of quality_level_indices array.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_quality_level_indices (scanbotsdk_document_quality_analyzer_configuration_t *self, scanbotsdk_document_quality_t *quality_level_indices, size_t quality_level_indices_size)
 Sets value of quality_level_indices field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_input_scales (scanbotsdk_document_quality_analyzer_configuration_t *self, double **input_scales)
 Returns value of input_scales field of the given object. The returned value is direct view into memory, no pre-allocations needed.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_input_scales_size (scanbotsdk_document_quality_analyzer_configuration_t *self, size_t *size)
 Returns size of input_scales array.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_input_scales (scanbotsdk_document_quality_analyzer_configuration_t *self, double *input_scales, size_t input_scales_size)
 Sets value of input_scales field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_input_scale_threshold_to_process_entire_image (scanbotsdk_document_quality_analyzer_configuration_t *self, double *input_scale_threshold_to_process_entire_image)
 Returns value of input_scale_threshold_to_process_entire_image field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_input_scale_threshold_to_process_entire_image (scanbotsdk_document_quality_analyzer_configuration_t *self, double input_scale_threshold_to_process_entire_image)
 Sets value of input_scale_threshold_to_process_entire_image field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_max_image_size (scanbotsdk_document_quality_analyzer_configuration_t *self, int *max_image_size)
 Returns value of max_image_size field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_max_image_size (scanbotsdk_document_quality_analyzer_configuration_t *self, int max_image_size)
 Sets value of max_image_size field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_min_estimated_number_of_symbols_for_document (scanbotsdk_document_quality_analyzer_configuration_t *self, int *min_estimated_number_of_symbols_for_document)
 Returns value of min_estimated_number_of_symbols_for_document field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_min_estimated_number_of_symbols_for_document (scanbotsdk_document_quality_analyzer_configuration_t *self, int min_estimated_number_of_symbols_for_document)
 Sets value of min_estimated_number_of_symbols_for_document field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_process_by_tile_configuration (scanbotsdk_document_quality_analyzer_configuration_t *self, scanbotsdk_process_by_tile_configuration_t **process_by_tile_configuration)
 Returns value of process_by_tile_configuration field of the given object. The returned pointers do NOT own the underlying object, caller must not free them.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_process_by_tile_configuration (scanbotsdk_document_quality_analyzer_configuration_t *self, scanbotsdk_process_by_tile_configuration_t *process_by_tile_configuration)
 Sets value of process_by_tile_configuration field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_min_required_orientation_confidence (scanbotsdk_document_quality_analyzer_configuration_t *self, double *min_required_orientation_confidence)
 Returns value of min_required_orientation_confidence field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_min_required_orientation_confidence (scanbotsdk_document_quality_analyzer_configuration_t *self, double min_required_orientation_confidence)
 Sets value of min_required_orientation_confidence field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_return_quality_heatmap (scanbotsdk_document_quality_analyzer_configuration_t *self, bool *return_quality_heatmap)
 Returns value of return_quality_heatmap field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_return_quality_heatmap (scanbotsdk_document_quality_analyzer_configuration_t *self, bool return_quality_heatmap)
 Sets value of return_quality_heatmap field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_compatibility_mode (scanbotsdk_document_quality_analyzer_configuration_t *self, scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t **compatibility_mode)
 Returns value of compatibility_mode field of the given object. The returned pointers do NOT own the underlying object, caller must not free them.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_compatibility_mode (scanbotsdk_document_quality_analyzer_configuration_t *self, scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t *compatibility_mode)
 Sets value of compatibility_mode field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_free (scanbotsdk_character_level_annotation_t *object)
 Frees the memory allocated for the instance of scanbotsdk_character_level_annotation_t. If null is passed, the function does nothing.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_get_plot_center (scanbotsdk_character_level_annotation_t *self, scanbotsdk_pointf_t *plot_center)
 Returns value of plot_center field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_get_plot_width (scanbotsdk_character_level_annotation_t *self, double *plot_width)
 Returns value of plot_width field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_get_plot_height (scanbotsdk_character_level_annotation_t *self, double *plot_height)
 Returns value of plot_height field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_get_ocrability (scanbotsdk_character_level_annotation_t *self, double *ocrability)
 Returns value of ocrability field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_get_contrast (scanbotsdk_character_level_annotation_t *self, double *contrast)
 Returns value of contrast field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_get_font_size (scanbotsdk_character_level_annotation_t *self, double *font_size)
 Returns value of font_size field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_get_orientation (scanbotsdk_character_level_annotation_t *self, double *orientation)
 Returns value of orientation field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_get_orientation_normalized (scanbotsdk_character_level_annotation_t *self, double *orientation_normalized)
 Returns value of orientation_normalized field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_get_orientation_deviation (scanbotsdk_character_level_annotation_t *self, double *orientation_deviation)
 Returns value of orientation_deviation field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotations_free (scanbotsdk_character_level_annotations_t *object)
 Frees the memory allocated for the instance of scanbotsdk_character_level_annotations_t. If null is passed, the function does nothing.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotations_get_annotations (scanbotsdk_character_level_annotations_t *self, scanbotsdk_character_level_annotation_t **annotations, size_t size)
 Returns value of annotations field of the given object. The returned pointers do NOT own the underlying object, caller must not free them.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotations_get_annotations_size (scanbotsdk_character_level_annotations_t *self, size_t *size)
 Returns size of annotations array.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotations_get_api_version (scanbotsdk_character_level_annotations_t *self, const char **api_version)
 Returns value of api_version field of the given object. The returned pointers do NOT own the underlying object, caller must not free them.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_training_data_free (scanbotsdk_document_quality_analyzer_training_data_t *object)
 Frees the memory allocated for the instance of scanbotsdk_document_quality_analyzer_training_data_t. If null is passed, the function does nothing.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_training_data_get_character_level_annotations (scanbotsdk_document_quality_analyzer_training_data_t *self, scanbotsdk_character_level_annotations_t **character_level_annotations)
 Returns value of character_level_annotations field of the given object. The returned pointers do NOT own the underlying object, caller must not free them.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_free (scanbotsdk_document_quality_analyzer_result_t *object)
 Frees the memory allocated for the instance of scanbotsdk_document_quality_analyzer_result_t. If null is passed, the function does nothing.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_get_quality (scanbotsdk_document_quality_analyzer_result_t *self, scanbotsdk_document_quality_assessment_t *quality)
 Returns value of quality field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_get_document_found (scanbotsdk_document_quality_analyzer_result_t *self, bool *document_found)
 Returns value of document_found field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_get_quality_level (scanbotsdk_document_quality_analyzer_result_t *self, scanbotsdk_document_quality_t **quality_level)
 Returns value of quality_level field of the given object. The returned pointers do NOT own the underlying object, caller must not free them.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_get_orientation (scanbotsdk_document_quality_analyzer_result_t *self, double *orientation)
 Returns value of orientation field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_get_orientation_confidence (scanbotsdk_document_quality_analyzer_result_t *self, double *orientation_confidence)
 Returns value of orientation_confidence field of the given object.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_get_cumulative_quality_histogram (scanbotsdk_document_quality_analyzer_result_t *self, int **cumulative_quality_histogram)
 Returns value of cumulative_quality_histogram field of the given object. The returned value is direct view into memory, no pre-allocations needed.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_get_cumulative_quality_histogram_size (scanbotsdk_document_quality_analyzer_result_t *self, size_t *size)
 Returns size of cumulative_quality_histogram array.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_get_quality_heatmap (scanbotsdk_document_quality_analyzer_result_t *self, scanbotsdk_image_t **quality_heatmap)
 Returns value of quality_heatmap field of the given object. The returned pointers do NOT own the underlying object, caller must not free them.
 
SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_get_best_input_scale (scanbotsdk_document_quality_analyzer_result_t *self, double *best_input_scale)
 Returns value of best_input_scale field of the given object.
 

Detailed Description

Typedef Documentation

◆ scanbotsdk_character_level_annotation_t

scanbotsdk_character_level_annotation_t class

Character level annotation, contains information about the quality of a character in the document.

◆ scanbotsdk_character_level_annotations_t

scanbotsdk_character_level_annotations_t class

Character level annotations, contains information about each character in the document.

◆ scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t

scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t class

Configuration for the compatibility mode of the Document Quality Analyzer. In this mode, the analyzer will return results that are identical to older versions of the SDK.

◆ scanbotsdk_document_quality_analyzer_compatibility_mode_t

scanbotsdk_document_quality_analyzer_compatibility_mode_t enum

Compatibility mode for the Document Quality Analyzer. In this mode, the analyzer will return results that are identical to older versions of the SDK.

◆ scanbotsdk_document_quality_analyzer_configuration_t

scanbotsdk_document_quality_analyzer_configuration_t class

Document Quality Analyzer configuration

The document quality analysis of a document can be slow on low end devices. To speed up the analysis, only parts of the the document can be analyzed. This can yield faster results but may result in less accurate predictions. The configuration parameters minProcessedFraction and maxProcessedFraction define a range of the image that will be analyzed. In that range, minNumberOfRequiredSymbols and minRequiredOrientationConfidence define under which conditions the analysis will stop early.

◆ scanbotsdk_document_quality_analyzer_result_t

scanbotsdk_document_quality_analyzer_result_t class

Result of document quality analysis. It can be used to determine, e.g., if a document is good enough to be used for OCR processing.

◆ scanbotsdk_document_quality_analyzer_t

scanbotsdk_document_quality_analyzer_t class

API for analyzing document quality.

Required licence feature(s): ImageProcessing.

◆ scanbotsdk_document_quality_analyzer_training_data_t

◆ scanbotsdk_document_quality_assessment_t

◆ scanbotsdk_document_quality_t

scanbotsdk_document_quality_t enum

Deprecated, please use DocumentQualityAssessment instead. Result of document quality analysis.

◆ scanbotsdk_document_quality_threshold_t

scanbotsdk_document_quality_threshold_t class

Point in the quality-number of symbols space to separate quality levels.

◆ scanbotsdk_process_by_tile_configuration_t

scanbotsdk_process_by_tile_configuration_t class

Configuration for processing image by tiles. This can be used to make the document quality analyzer processing faster with lower memory consumption, but prediction can be less accurate.

Enumeration Type Documentation

◆ scanbotsdk_document_quality_analyzer_compatibility_mode_t

scanbotsdk_document_quality_analyzer_compatibility_mode_t enum

Compatibility mode for the Document Quality Analyzer. In this mode, the analyzer will return results that are identical to older versions of the SDK.

Enumerator
SCANBOTSDK_DOCUMENT_QUALITY_ANALYZER_COMPATIBILITY_MODE_V8 

Compatible with version 8 of the Scanbot SDK.

◆ scanbotsdk_document_quality_assessment_t

scanbotsdk_document_quality_assessment_t enum

Result of document quality analysis.

Enumerator
SCANBOTSDK_DOCUMENT_QUALITY_ASSESSMENT_ACCEPTABLE 

Document meets the quality requirements of the given quality analysis model.

SCANBOTSDK_DOCUMENT_QUALITY_ASSESSMENT_UNACCEPTABLE 

Document does not meet the quality requirements of the given quality analysis model.

SCANBOTSDK_DOCUMENT_QUALITY_ASSESSMENT_UNCERTAIN 

Document quality is uncertain. See qualityAcceptableUncertainThreshold and qualityUnacceptableUncertainThreshold in DocumentQualityAnalyzerConfiguration for more details.

◆ scanbotsdk_document_quality_t

scanbotsdk_document_quality_t enum

Deprecated, please use DocumentQualityAssessment instead. Result of document quality analysis.

Enumerator
SCANBOTSDK_DOCUMENT_QUALITY_VERY_POOR 

Very poor quality.

SCANBOTSDK_DOCUMENT_QUALITY_POOR 

Poor quality.

SCANBOTSDK_DOCUMENT_QUALITY_REASONABLE 

Reasonable quality.

SCANBOTSDK_DOCUMENT_QUALITY_GOOD 

Good quality.

SCANBOTSDK_DOCUMENT_QUALITY_EXCELLENT 

Excellent quality.

Function Documentation

◆ scanbotsdk_character_level_annotation_free()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_free ( scanbotsdk_character_level_annotation_t * object)

Frees the memory allocated for the instance of scanbotsdk_character_level_annotation_t. If null is passed, the function does nothing.

Parameters
objectPointer to the instance of scanbotsdk_character_level_annotation_t to be freed
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_character_level_annotation_get_contrast()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_get_contrast ( scanbotsdk_character_level_annotation_t * self,
double * contrast )

Returns value of contrast field of the given object.

Estimated contrast of the character, in the range of [0, 1], where 0 means no contrast and 1 means perfect contrast.

Parameters
selfPointer to the instance of scanbotsdk_character_level_annotation_t
contrastPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_character_level_annotation_get_font_size()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_get_font_size ( scanbotsdk_character_level_annotation_t * self,
double * font_size )

Returns value of font_size field of the given object.

Estimated height of the character in pixels.

Parameters
selfPointer to the instance of scanbotsdk_character_level_annotation_t
font_sizePointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_character_level_annotation_get_ocrability()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_get_ocrability ( scanbotsdk_character_level_annotation_t * self,
double * ocrability )

Returns value of ocrability field of the given object.

Estimated OCRability of the character, in the range of [0, 1], where 0 means not readable and 1 means perfect readability.

Parameters
selfPointer to the instance of scanbotsdk_character_level_annotation_t
ocrabilityPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_character_level_annotation_get_orientation()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_get_orientation ( scanbotsdk_character_level_annotation_t * self,
double * orientation )

Returns value of orientation field of the given object.

Orientation of the character in degrees counter-clockwise, where 0 means straight, and the value is in the range of [-180, 180].

Parameters
selfPointer to the instance of scanbotsdk_character_level_annotation_t
orientationPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_character_level_annotation_get_orientation_deviation()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_get_orientation_deviation ( scanbotsdk_character_level_annotation_t * self,
double * orientation_deviation )

Returns value of orientation_deviation field of the given object.

Deviation of the character's normalized orientation from dominant orientation of the line, in degrees.

Parameters
selfPointer to the instance of scanbotsdk_character_level_annotation_t
orientation_deviationPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_character_level_annotation_get_orientation_normalized()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_get_orientation_normalized ( scanbotsdk_character_level_annotation_t * self,
double * orientation_normalized )

Returns value of orientation_normalized field of the given object.

Same as orientation, but takes into account surrounding characters to smooth the orientation values of characters in a line.

Parameters
selfPointer to the instance of scanbotsdk_character_level_annotation_t
orientation_normalizedPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_character_level_annotation_get_plot_center()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_get_plot_center ( scanbotsdk_character_level_annotation_t * self,
scanbotsdk_pointf_t * plot_center )

Returns value of plot_center field of the given object.

Coordinates of the character's center in the image. The coordinates are in pixels, with (0, 0) being the top-left corner of the image. The rectangle described by the plotCenter, plotWidth, and plotHeight fields serve as a rough estimate of the position of the character in the input image, intended for plotting.

Parameters
selfPointer to the instance of scanbotsdk_character_level_annotation_t
plot_centerPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_character_level_annotation_get_plot_height()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_get_plot_height ( scanbotsdk_character_level_annotation_t * self,
double * plot_height )

Returns value of plot_height field of the given object.

Height of the character in pixels.

Parameters
selfPointer to the instance of scanbotsdk_character_level_annotation_t
plot_heightPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_character_level_annotation_get_plot_width()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotation_get_plot_width ( scanbotsdk_character_level_annotation_t * self,
double * plot_width )

Returns value of plot_width field of the given object.

Width of the character in pixels.

Parameters
selfPointer to the instance of scanbotsdk_character_level_annotation_t
plot_widthPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_character_level_annotations_free()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotations_free ( scanbotsdk_character_level_annotations_t * object)

Frees the memory allocated for the instance of scanbotsdk_character_level_annotations_t. If null is passed, the function does nothing.

Parameters
objectPointer to the instance of scanbotsdk_character_level_annotations_t to be freed
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_character_level_annotations_get_annotations()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotations_get_annotations ( scanbotsdk_character_level_annotations_t * self,
scanbotsdk_character_level_annotation_t ** annotations,
size_t size )

Returns value of annotations field of the given object. The returned pointers do NOT own the underlying object, caller must not free them.

List of character level annotations.

Parameters
selfPointer to the instance of scanbotsdk_character_level_annotations_t
sizeSize of the pre-allocated array. Must be equal to the size obtained by calling the corresponding _size function.
annotationsPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_character_level_annotations_get_annotations_size()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotations_get_annotations_size ( scanbotsdk_character_level_annotations_t * self,
size_t * size )

Returns size of annotations array.

Parameters
selfPointer to the instance of scanbotsdk_character_level_annotations_t
sizePointer to a variable that will store the size.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_character_level_annotations_get_api_version()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_character_level_annotations_get_api_version ( scanbotsdk_character_level_annotations_t * self,
const char ** api_version )

Returns value of api_version field of the given object. The returned pointers do NOT own the underlying object, caller must not free them.

Version of the model and code used to generate the annotations.

Parameters
selfPointer to the instance of scanbotsdk_character_level_annotations_t
api_versionPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_create()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_create ( scanbotsdk_document_quality_analyzer_compatibility_mode_t mode,
scanbotsdk_document_quality_t minimum_acceptable_quality,
scanbotsdk_document_quality_t minimum_uncertain_quality,
bool inspect_small_text,
scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t ** result )

Creates a new instance of scanbotsdk_document_quality_analyzer_compatibility_mode_configuration with given params and stores it in the location specified by the last argument.

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
modeCompatibility mode to use.

Default is V8

Parameters
minimum_acceptable_qualityThis setting describes how the Document Quality Analyzer in v8 compatibility mode will behave. Minimum compatibility-mode quality that gets converted to DocumentQualityAssessment.ACCEPTABLE. Compatibility-mode quality levels equal to or higher than minimumAcceptableQuality result in an ACCEPTABLE quality assessment.

Default is REASONABLE

Parameters
minimum_uncertain_qualityMinimum compatibility-mode quality that gets converted to DocumentQualityAssessment.UNCERTAIN. Compatibility-mode quality levels between minimumUncertainQuality (inclusive) and minimumAcceptableQuality (exclusive) result in an UNCERTAIN quality assessment.

Default is POOR

Parameters
inspect_small_textInspect small text (typically less than 12 pixels height) when analyzing the document quality. If true, processing will be slower, but when the quality issue with a document is the low resolution of the text, then the issue will be caught.

Default is false

Parameters
resultPointer to a variable that will store the created instance of scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_create_with_defaults()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_create_with_defaults ( scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t ** result)

Creates a new instance of scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t with given required params and stores it in the location specified by the last argument.

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
resultPointer to a variable that will store the created instance of scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_free()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_free ( scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t * object)

Frees the memory allocated for the instance of scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t. If null is passed, the function does nothing.

Parameters
objectPointer to the instance of scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t to be freed
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_get_inspect_small_text()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_get_inspect_small_text ( scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t * self,
bool * inspect_small_text )

Returns value of inspect_small_text field of the given object.

Inspect small text (typically less than 12 pixels height) when analyzing the document quality. If true, processing will be slower, but when the quality issue with a document is the low resolution of the text, then the issue will be caught.

Default is false

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t
inspect_small_textPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_get_minimum_acceptable_quality()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_get_minimum_acceptable_quality ( scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t * self,
scanbotsdk_document_quality_t * minimum_acceptable_quality )

Returns value of minimum_acceptable_quality field of the given object.

This setting describes how the Document Quality Analyzer in v8 compatibility mode will behave. Minimum compatibility-mode quality that gets converted to DocumentQualityAssessment.ACCEPTABLE. Compatibility-mode quality levels equal to or higher than minimumAcceptableQuality result in an ACCEPTABLE quality assessment.

Default is REASONABLE

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t
minimum_acceptable_qualityPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_get_minimum_uncertain_quality()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_get_minimum_uncertain_quality ( scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t * self,
scanbotsdk_document_quality_t * minimum_uncertain_quality )

Returns value of minimum_uncertain_quality field of the given object.

Minimum compatibility-mode quality that gets converted to DocumentQualityAssessment.UNCERTAIN. Compatibility-mode quality levels between minimumUncertainQuality (inclusive) and minimumAcceptableQuality (exclusive) result in an UNCERTAIN quality assessment.

Default is POOR

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t
minimum_uncertain_qualityPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_get_mode()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_get_mode ( scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t * self,
scanbotsdk_document_quality_analyzer_compatibility_mode_t * mode )

Returns value of mode field of the given object.

Compatibility mode to use.

Default is V8

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t
modePointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_set_inspect_small_text()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_set_inspect_small_text ( scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t * self,
bool inspect_small_text )

Sets value of inspect_small_text field of the given object.

Inspect small text (typically less than 12 pixels height) when analyzing the document quality. If true, processing will be slower, but when the quality issue with a document is the low resolution of the text, then the issue will be caught.

Default is false

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t, the field of which will be set
inspect_small_textThe value to be set.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_set_minimum_acceptable_quality()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_set_minimum_acceptable_quality ( scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t * self,
scanbotsdk_document_quality_t minimum_acceptable_quality )

Sets value of minimum_acceptable_quality field of the given object.

This setting describes how the Document Quality Analyzer in v8 compatibility mode will behave. Minimum compatibility-mode quality that gets converted to DocumentQualityAssessment.ACCEPTABLE. Compatibility-mode quality levels equal to or higher than minimumAcceptableQuality result in an ACCEPTABLE quality assessment.

Default is REASONABLE

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t, the field of which will be set
minimum_acceptable_qualityThe value to be set.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_set_minimum_uncertain_quality()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_set_minimum_uncertain_quality ( scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t * self,
scanbotsdk_document_quality_t minimum_uncertain_quality )

Sets value of minimum_uncertain_quality field of the given object.

Minimum compatibility-mode quality that gets converted to DocumentQualityAssessment.UNCERTAIN. Compatibility-mode quality levels between minimumUncertainQuality (inclusive) and minimumAcceptableQuality (exclusive) result in an UNCERTAIN quality assessment.

Default is POOR

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t, the field of which will be set
minimum_uncertain_qualityThe value to be set.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_compatibility_mode_t_to_string()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_compatibility_mode_t_to_string ( scanbotsdk_document_quality_analyzer_compatibility_mode_t value,
const char ** result )

Returns the string representation of the given scanbotsdk_document_quality_analyzer_compatibility_mode_t value.

The returned string doesn't need to be freed.

Parameters
valueThe value to be converted to string.
resultPointer to a variable that will store the string representation of the value.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_configuration_create()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_create ( const char * quality_analysis_model,
double quality_acceptable_uncertain_threshold,
double quality_unacceptable_uncertain_threshold,
scanbotsdk_document_quality_threshold_t ** quality_level_thresholds,
size_t quality_level_thresholds_size,
scanbotsdk_document_quality_t * quality_level_indices,
size_t quality_level_indices_size,
double * input_scales,
size_t input_scales_size,
double input_scale_threshold_to_process_entire_image,
int max_image_size,
int min_estimated_number_of_symbols_for_document,
scanbotsdk_process_by_tile_configuration_t * process_by_tile_configuration,
double min_required_orientation_confidence,
bool return_quality_heatmap,
scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t * compatibility_mode,
scanbotsdk_document_quality_analyzer_configuration_t ** result )

Creates a new instance of scanbotsdk_document_quality_analyzer_configuration with given params and stores it in the location specified by the last argument.

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
quality_analysis_modelDocument quality analysis model to use. If empty, the built-in model is used which provides reasonable quality estimates for a wide variety of documents. If the built-in model is not a good fit for your use case, consider creating a model based on your own documents and use case.

To create a fine-tuned quality analysis model, follow the documentation of our DoQA model configurator tool. You can find it here: https://github.com/doo/scanbot-sdk-doqa-configurator.

Default is "" The value must not be null.

Parameters
quality_acceptable_uncertain_thresholdThere are documents for which the quality analysis model is uncertain, meaning that the model is not sure if the document is acceptable or not. E.g., the model may report a document quality to be ACCEPTABLE with 60% confidence. Depending on the value of this threshold, the document in this case will be reported as ACCEPTABLE or UNCERTAIN. The default value of 0.5 will typically lead to a good balance between the number of documents reported as ACCEPTABLE and UNCERTAIN. A lower value will lead to fewer UNCERTAIN documents, but unacceptable documents will more often be reported as ACCEPTABLE (false positives). A higher value will lead to more borderline documents being reported as UNCERTAIN, but unacceptable documents will be reported as ACCEPTABLE less often. If 0, no documents with a predicted quality of ACCEPTABLE will be reported as UNCERTAIN, regardless of the model's confidence, unless the document has very few symbols (see minEstimatedNumberOfSymbolsForDocument). If 1, almost all documents with a predicted quality of ACCEPTABLE will be reported as UNCERTAIN. Must be in the range of [0, 1].

Default is 0.5

Parameters
quality_unacceptable_uncertain_thresholdSame as qualityAcceptableUncertainThreshold, but for documents that are predicted to be UNACCEPTABLE by the model.

Default is 0.5

Parameters
quality_level_thresholdsDeprecated, please use qualityAnalysisModel instead. Quality thresholds to separate quality levels. Entries of the array must not be null.
quality_level_thresholds_sizeSize of the array quality_level_thresholds
quality_level_indicesDeprecated, please use qualityAnalysisModel instead. Quality levels.
quality_level_indices_sizeSize of the array quality_level_indices
input_scalesRuns the Document Quality Analyzer on the listed inputScales. Only the best result will be returned. Typical range of the text height, which model can work with, is 5-40 pixels. 10 pixels height is recommended. Use this option if documents with smaller or bigger texts are expected. For example, if 80 pixels text height is expected, scale should be 1/8. Not compatible with maxImageSize. If not [1] maxImageSize should be less or equal 0.
input_scales_sizeSize of the array input_scales
input_scale_threshold_to_process_entire_imageIf inputScale from inputScales is smaller or equal than the threshold minProcessedFraction and maxProcessedFraction will be ignored, and the entire image will be processed.

Default is 0.25

Parameters
max_image_sizeMaximum image size in pixels, if image is bigger, it will be resized. If less or equal 0 will be ignored.

Default is 2000

Parameters
min_estimated_number_of_symbols_for_documentIf a document's estimated number of symbols is less than this value, document quality will be reported as UNCERTAIN. In that case, the deprecated result fields documentFound andqualityLevel will be set to false and empty, respectively.

Default is 20

Parameters
process_by_tile_configurationConfiguration for processing image by tiles. The value must not be null.
min_required_orientation_confidenceIf detectOrientation is True, minNumberOfRequiredSymbols is found, and orientationConfidence is bigger than this threshold, the processing stops. If the maxProcessedFraction part of the image is processed and orientationConfidence is lower than the threshold, the returned orientation will be 0.

Default is 0.9

Parameters
return_quality_heatmapIf true, will return the quality heatmap as a part of the result. In this case, the entire image will be processed and the minProcessedFraction will be ignored. Useful for debugging situations where the returned quality doesn't appear to match the perceived quality.

Default is false

Parameters
compatibility_modeCompatibility mode for the Document Quality Analyzer. If set, the analyzer will return results that are identical to older versions of the SDK. The value can be null.
resultPointer to a variable that will store the created instance of scanbotsdk_document_quality_analyzer_configuration_t
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_configuration_create_with_defaults()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_create_with_defaults ( scanbotsdk_document_quality_analyzer_configuration_t ** result)

Creates a new instance of scanbotsdk_document_quality_analyzer_configuration_t with given required params and stores it in the location specified by the last argument.

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
resultPointer to a variable that will store the created instance of scanbotsdk_document_quality_analyzer_configuration_t
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_configuration_free()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_free ( scanbotsdk_document_quality_analyzer_configuration_t * object)

Frees the memory allocated for the instance of scanbotsdk_document_quality_analyzer_configuration_t. If null is passed, the function does nothing.

Parameters
objectPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t to be freed
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_configuration_get_compatibility_mode()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_compatibility_mode ( scanbotsdk_document_quality_analyzer_configuration_t * self,
scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t ** compatibility_mode )

Returns value of compatibility_mode field of the given object. The returned pointers do NOT own the underlying object, caller must not free them.

Compatibility mode for the Document Quality Analyzer. If set, the analyzer will return results that are identical to older versions of the SDK.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t
compatibility_modePointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_configuration_get_input_scale_threshold_to_process_entire_image()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_input_scale_threshold_to_process_entire_image ( scanbotsdk_document_quality_analyzer_configuration_t * self,
double * input_scale_threshold_to_process_entire_image )

Returns value of input_scale_threshold_to_process_entire_image field of the given object.

If inputScale from inputScales is smaller or equal than the threshold minProcessedFraction and maxProcessedFraction will be ignored, and the entire image will be processed.

Default is 0.25

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t
input_scale_threshold_to_process_entire_imagePointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_configuration_get_input_scales()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_input_scales ( scanbotsdk_document_quality_analyzer_configuration_t * self,
double ** input_scales )

Returns value of input_scales field of the given object. The returned value is direct view into memory, no pre-allocations needed.

Runs the Document Quality Analyzer on the listed inputScales. Only the best result will be returned. Typical range of the text height, which model can work with, is 5-40 pixels. 10 pixels height is recommended. Use this option if documents with smaller or bigger texts are expected. For example, if 80 pixels text height is expected, scale should be 1/8. Not compatible with maxImageSize. If not [1] maxImageSize should be less or equal 0.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t
input_scalesPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_configuration_get_input_scales_size()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_input_scales_size ( scanbotsdk_document_quality_analyzer_configuration_t * self,
size_t * size )

Returns size of input_scales array.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t
sizePointer to a variable that will store the size.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_configuration_get_max_image_size()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_max_image_size ( scanbotsdk_document_quality_analyzer_configuration_t * self,
int * max_image_size )

Returns value of max_image_size field of the given object.

Maximum image size in pixels, if image is bigger, it will be resized. If less or equal 0 will be ignored.

Default is 2000

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t
max_image_sizePointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_configuration_get_min_estimated_number_of_symbols_for_document()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_min_estimated_number_of_symbols_for_document ( scanbotsdk_document_quality_analyzer_configuration_t * self,
int * min_estimated_number_of_symbols_for_document )

Returns value of min_estimated_number_of_symbols_for_document field of the given object.

If a document's estimated number of symbols is less than this value, document quality will be reported as UNCERTAIN. In that case, the deprecated result fields documentFound andqualityLevel will be set to false and empty, respectively.

Default is 20

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t
min_estimated_number_of_symbols_for_documentPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_configuration_get_min_required_orientation_confidence()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_min_required_orientation_confidence ( scanbotsdk_document_quality_analyzer_configuration_t * self,
double * min_required_orientation_confidence )

Returns value of min_required_orientation_confidence field of the given object.

If detectOrientation is True, minNumberOfRequiredSymbols is found, and orientationConfidence is bigger than this threshold, the processing stops. If the maxProcessedFraction part of the image is processed and orientationConfidence is lower than the threshold, the returned orientation will be 0.

Default is 0.9

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t
min_required_orientation_confidencePointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_configuration_get_process_by_tile_configuration()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_process_by_tile_configuration ( scanbotsdk_document_quality_analyzer_configuration_t * self,
scanbotsdk_process_by_tile_configuration_t ** process_by_tile_configuration )

Returns value of process_by_tile_configuration field of the given object. The returned pointers do NOT own the underlying object, caller must not free them.

Configuration for processing image by tiles.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t
process_by_tile_configurationPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_configuration_get_quality_acceptable_uncertain_threshold()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_quality_acceptable_uncertain_threshold ( scanbotsdk_document_quality_analyzer_configuration_t * self,
double * quality_acceptable_uncertain_threshold )

Returns value of quality_acceptable_uncertain_threshold field of the given object.

There are documents for which the quality analysis model is uncertain, meaning that the model is not sure if the document is acceptable or not. E.g., the model may report a document quality to be ACCEPTABLE with 60% confidence. Depending on the value of this threshold, the document in this case will be reported as ACCEPTABLE or UNCERTAIN. The default value of 0.5 will typically lead to a good balance between the number of documents reported as ACCEPTABLE and UNCERTAIN. A lower value will lead to fewer UNCERTAIN documents, but unacceptable documents will more often be reported as ACCEPTABLE (false positives). A higher value will lead to more borderline documents being reported as UNCERTAIN, but unacceptable documents will be reported as ACCEPTABLE less often. If 0, no documents with a predicted quality of ACCEPTABLE will be reported as UNCERTAIN, regardless of the model's confidence, unless the document has very few symbols (see minEstimatedNumberOfSymbolsForDocument). If 1, almost all documents with a predicted quality of ACCEPTABLE will be reported as UNCERTAIN. Must be in the range of [0, 1].

Default is 0.5

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t
quality_acceptable_uncertain_thresholdPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_configuration_get_quality_analysis_model()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_quality_analysis_model ( scanbotsdk_document_quality_analyzer_configuration_t * self,
const char ** quality_analysis_model )

Returns value of quality_analysis_model field of the given object. The returned pointers do NOT own the underlying object, caller must not free them.

Document quality analysis model to use. If empty, the built-in model is used which provides reasonable quality estimates for a wide variety of documents. If the built-in model is not a good fit for your use case, consider creating a model based on your own documents and use case.

To create a fine-tuned quality analysis model, follow the documentation of our DoQA model configurator tool. You can find it here: https://github.com/doo/scanbot-sdk-doqa-configurator.

Default is ""

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t
quality_analysis_modelPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_configuration_get_quality_level_indices()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_quality_level_indices ( scanbotsdk_document_quality_analyzer_configuration_t * self,
scanbotsdk_document_quality_t ** quality_level_indices )

Returns value of quality_level_indices field of the given object. The returned value is direct view into memory, no pre-allocations needed.

Deprecated, please use qualityAnalysisModel instead. Quality levels.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t
quality_level_indicesPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_configuration_get_quality_level_indices_size()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_quality_level_indices_size ( scanbotsdk_document_quality_analyzer_configuration_t * self,
size_t * size )

Returns size of quality_level_indices array.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t
sizePointer to a variable that will store the size.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_configuration_get_quality_level_thresholds()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_quality_level_thresholds ( scanbotsdk_document_quality_analyzer_configuration_t * self,
scanbotsdk_document_quality_threshold_t ** quality_level_thresholds,
size_t size )

Returns value of quality_level_thresholds field of the given object. The returned pointers do NOT own the underlying object, caller must not free them.

Deprecated, please use qualityAnalysisModel instead. Quality thresholds to separate quality levels.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t
sizeSize of the pre-allocated array. Must be equal to the size obtained by calling the corresponding _size function.
quality_level_thresholdsPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_configuration_get_quality_level_thresholds_size()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_quality_level_thresholds_size ( scanbotsdk_document_quality_analyzer_configuration_t * self,
size_t * size )

Returns size of quality_level_thresholds array.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t
sizePointer to a variable that will store the size.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_configuration_get_quality_unacceptable_uncertain_threshold()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_quality_unacceptable_uncertain_threshold ( scanbotsdk_document_quality_analyzer_configuration_t * self,
double * quality_unacceptable_uncertain_threshold )

Returns value of quality_unacceptable_uncertain_threshold field of the given object.

Same as qualityAcceptableUncertainThreshold, but for documents that are predicted to be UNACCEPTABLE by the model.

Default is 0.5

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t
quality_unacceptable_uncertain_thresholdPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_configuration_get_return_quality_heatmap()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_get_return_quality_heatmap ( scanbotsdk_document_quality_analyzer_configuration_t * self,
bool * return_quality_heatmap )

Returns value of return_quality_heatmap field of the given object.

If true, will return the quality heatmap as a part of the result. In this case, the entire image will be processed and the minProcessedFraction will be ignored. Useful for debugging situations where the returned quality doesn't appear to match the perceived quality.

Default is false

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t
return_quality_heatmapPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_configuration_set_compatibility_mode()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_compatibility_mode ( scanbotsdk_document_quality_analyzer_configuration_t * self,
scanbotsdk_document_quality_analyzer_compatibility_mode_configuration_t * compatibility_mode )

Sets value of compatibility_mode field of the given object.

Compatibility mode for the Document Quality Analyzer. If set, the analyzer will return results that are identical to older versions of the SDK.

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t, the field of which will be set
compatibility_modeThe value to be set. Can be null.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_configuration_set_input_scale_threshold_to_process_entire_image()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_input_scale_threshold_to_process_entire_image ( scanbotsdk_document_quality_analyzer_configuration_t * self,
double input_scale_threshold_to_process_entire_image )

Sets value of input_scale_threshold_to_process_entire_image field of the given object.

If inputScale from inputScales is smaller or equal than the threshold minProcessedFraction and maxProcessedFraction will be ignored, and the entire image will be processed.

Default is 0.25

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t, the field of which will be set
input_scale_threshold_to_process_entire_imageThe value to be set.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_configuration_set_input_scales()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_input_scales ( scanbotsdk_document_quality_analyzer_configuration_t * self,
double * input_scales,
size_t input_scales_size )

Sets value of input_scales field of the given object.

Runs the Document Quality Analyzer on the listed inputScales. Only the best result will be returned. Typical range of the text height, which model can work with, is 5-40 pixels. 10 pixels height is recommended. Use this option if documents with smaller or bigger texts are expected. For example, if 80 pixels text height is expected, scale should be 1/8. Not compatible with maxImageSize. If not [1] maxImageSize should be less or equal 0.

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t, the field of which will be set
input_scalesThe value to be set.
input_scales_sizeSize of the array.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_configuration_set_max_image_size()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_max_image_size ( scanbotsdk_document_quality_analyzer_configuration_t * self,
int max_image_size )

Sets value of max_image_size field of the given object.

Maximum image size in pixels, if image is bigger, it will be resized. If less or equal 0 will be ignored.

Default is 2000

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t, the field of which will be set
max_image_sizeThe value to be set.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_configuration_set_min_estimated_number_of_symbols_for_document()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_min_estimated_number_of_symbols_for_document ( scanbotsdk_document_quality_analyzer_configuration_t * self,
int min_estimated_number_of_symbols_for_document )

Sets value of min_estimated_number_of_symbols_for_document field of the given object.

If a document's estimated number of symbols is less than this value, document quality will be reported as UNCERTAIN. In that case, the deprecated result fields documentFound andqualityLevel will be set to false and empty, respectively.

Default is 20

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t, the field of which will be set
min_estimated_number_of_symbols_for_documentThe value to be set.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_configuration_set_min_required_orientation_confidence()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_min_required_orientation_confidence ( scanbotsdk_document_quality_analyzer_configuration_t * self,
double min_required_orientation_confidence )

Sets value of min_required_orientation_confidence field of the given object.

If detectOrientation is True, minNumberOfRequiredSymbols is found, and orientationConfidence is bigger than this threshold, the processing stops. If the maxProcessedFraction part of the image is processed and orientationConfidence is lower than the threshold, the returned orientation will be 0.

Default is 0.9

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t, the field of which will be set
min_required_orientation_confidenceThe value to be set.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_configuration_set_process_by_tile_configuration()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_process_by_tile_configuration ( scanbotsdk_document_quality_analyzer_configuration_t * self,
scanbotsdk_process_by_tile_configuration_t * process_by_tile_configuration )

Sets value of process_by_tile_configuration field of the given object.

Configuration for processing image by tiles.

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t, the field of which will be set
process_by_tile_configurationThe value to be set. Must not be null.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_configuration_set_quality_acceptable_uncertain_threshold()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_quality_acceptable_uncertain_threshold ( scanbotsdk_document_quality_analyzer_configuration_t * self,
double quality_acceptable_uncertain_threshold )

Sets value of quality_acceptable_uncertain_threshold field of the given object.

There are documents for which the quality analysis model is uncertain, meaning that the model is not sure if the document is acceptable or not. E.g., the model may report a document quality to be ACCEPTABLE with 60% confidence. Depending on the value of this threshold, the document in this case will be reported as ACCEPTABLE or UNCERTAIN. The default value of 0.5 will typically lead to a good balance between the number of documents reported as ACCEPTABLE and UNCERTAIN. A lower value will lead to fewer UNCERTAIN documents, but unacceptable documents will more often be reported as ACCEPTABLE (false positives). A higher value will lead to more borderline documents being reported as UNCERTAIN, but unacceptable documents will be reported as ACCEPTABLE less often. If 0, no documents with a predicted quality of ACCEPTABLE will be reported as UNCERTAIN, regardless of the model's confidence, unless the document has very few symbols (see minEstimatedNumberOfSymbolsForDocument). If 1, almost all documents with a predicted quality of ACCEPTABLE will be reported as UNCERTAIN. Must be in the range of [0, 1].

Default is 0.5

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t, the field of which will be set
quality_acceptable_uncertain_thresholdThe value to be set.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_configuration_set_quality_analysis_model()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_quality_analysis_model ( scanbotsdk_document_quality_analyzer_configuration_t * self,
const char * quality_analysis_model )

Sets value of quality_analysis_model field of the given object.

Document quality analysis model to use. If empty, the built-in model is used which provides reasonable quality estimates for a wide variety of documents. If the built-in model is not a good fit for your use case, consider creating a model based on your own documents and use case.

To create a fine-tuned quality analysis model, follow the documentation of our DoQA model configurator tool. You can find it here: https://github.com/doo/scanbot-sdk-doqa-configurator.

Default is ""

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t, the field of which will be set
quality_analysis_modelThe value to be set. Must not be null.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_configuration_set_quality_level_indices()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_quality_level_indices ( scanbotsdk_document_quality_analyzer_configuration_t * self,
scanbotsdk_document_quality_t * quality_level_indices,
size_t quality_level_indices_size )

Sets value of quality_level_indices field of the given object.

Deprecated, please use qualityAnalysisModel instead. Quality levels.

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t, the field of which will be set
quality_level_indicesThe value to be set.
quality_level_indices_sizeSize of the array.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_configuration_set_quality_level_thresholds()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_quality_level_thresholds ( scanbotsdk_document_quality_analyzer_configuration_t * self,
scanbotsdk_document_quality_threshold_t ** quality_level_thresholds,
size_t quality_level_thresholds_size )

Sets value of quality_level_thresholds field of the given object.

Deprecated, please use qualityAnalysisModel instead. Quality thresholds to separate quality levels.

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t, the field of which will be set
quality_level_thresholdsThe value to be set.
quality_level_thresholds_sizeSize of the array.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_configuration_set_quality_unacceptable_uncertain_threshold()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_quality_unacceptable_uncertain_threshold ( scanbotsdk_document_quality_analyzer_configuration_t * self,
double quality_unacceptable_uncertain_threshold )

Sets value of quality_unacceptable_uncertain_threshold field of the given object.

Same as qualityAcceptableUncertainThreshold, but for documents that are predicted to be UNACCEPTABLE by the model.

Default is 0.5

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t, the field of which will be set
quality_unacceptable_uncertain_thresholdThe value to be set.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_configuration_set_return_quality_heatmap()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_configuration_set_return_quality_heatmap ( scanbotsdk_document_quality_analyzer_configuration_t * self,
bool return_quality_heatmap )

Sets value of return_quality_heatmap field of the given object.

If true, will return the quality heatmap as a part of the result. In this case, the entire image will be processed and the minProcessedFraction will be ignored. Useful for debugging situations where the returned quality doesn't appear to match the perceived quality.

Default is false

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_configuration_t, the field of which will be set
return_quality_heatmapThe value to be set.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_create()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_create ( scanbotsdk_document_quality_analyzer_configuration_t * configuration,
scanbotsdk_document_quality_analyzer_t ** result )

Creates a new instance of scanbotsdk_document_quality_analyzer with given params and stores it in the location specified by the last argument.

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
configurationThe configuration to use for the document quality analyzer. The value must not be null.
resultPointer to a variable that will store the created instance of scanbotsdk_document_quality_analyzer_t
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_free()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_free ( scanbotsdk_document_quality_analyzer_t * self)

Frees the memory allocated for the instance of scanbotsdk_document_quality_analyzer_t. If null is passed, the function does nothing.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_t to be freed
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_result_free()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_free ( scanbotsdk_document_quality_analyzer_result_t * object)

Frees the memory allocated for the instance of scanbotsdk_document_quality_analyzer_result_t. If null is passed, the function does nothing.

Parameters
objectPointer to the instance of scanbotsdk_document_quality_analyzer_result_t to be freed
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_result_get_best_input_scale()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_get_best_input_scale ( scanbotsdk_document_quality_analyzer_result_t * self,
double * best_input_scale )

Returns value of best_input_scale field of the given object.

Returns the best inputScale whose results are used (see inputScales configuration option).

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_result_t
best_input_scalePointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_result_get_cumulative_quality_histogram()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_get_cumulative_quality_histogram ( scanbotsdk_document_quality_analyzer_result_t * self,
int ** cumulative_quality_histogram )

Returns value of cumulative_quality_histogram field of the given object. The returned value is direct view into memory, no pre-allocations needed.

Cumulative histogram where every entry is equal to the number of symbols with quality equal or lower than N percent, where N is the index of the entry in the array.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_result_t
cumulative_quality_histogramPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_result_get_cumulative_quality_histogram_size()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_get_cumulative_quality_histogram_size ( scanbotsdk_document_quality_analyzer_result_t * self,
size_t * size )

Returns size of cumulative_quality_histogram array.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_result_t
sizePointer to a variable that will store the size.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_result_get_document_found()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_get_document_found ( scanbotsdk_document_quality_analyzer_result_t * self,
bool * document_found )

Returns value of document_found field of the given object.

Deprecated, please use quality instead, because it provides a more reliable result. True if a document was found.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_result_t
document_foundPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_result_get_orientation()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_get_orientation ( scanbotsdk_document_quality_analyzer_result_t * self,
double * orientation )

Returns value of orientation field of the given object.

Dominant orientation of the document, if found. The value is in degrees counter-clockwise, where 0 corresponds to the document being straight, and the value is in the range of [-180, 180]. To rotate the document to be straight, rotate the image clockwise by this value.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_result_t
orientationPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_result_get_orientation_confidence()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_get_orientation_confidence ( scanbotsdk_document_quality_analyzer_result_t * self,
double * orientation_confidence )

Returns value of orientation_confidence field of the given object.

Confidence that the reported orientation of the document is correct. The value is in the range of [0, 1]. Possible reasons for low confidence are:

  • Document contains text with multiple orientations.
  • Text on the document is poorly readable.
  • Text on the document is on the edge of detectable text range (text is too small or too big).
  • Insufficient statistics because only part of the image was processed. See ProcessByTileConfiguration options in the DocumentQualityAnalyzerConfiguration.
    Parameters
    selfPointer to the instance of scanbotsdk_document_quality_analyzer_result_t
    orientation_confidencePointer to a variable that will store the value of the field.
    Returns
    : Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_result_get_quality()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_get_quality ( scanbotsdk_document_quality_analyzer_result_t * self,
scanbotsdk_document_quality_assessment_t * quality )

Returns value of quality field of the given object.

Document quality as estimated from the given quality analysis model.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_result_t
qualityPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_result_get_quality_heatmap()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_get_quality_heatmap ( scanbotsdk_document_quality_analyzer_result_t * self,
scanbotsdk_image_t ** quality_heatmap )

Returns value of quality_heatmap field of the given object. The returned pointers do NOT own the underlying object, caller must not free them.

Quality heatmap. Black marks areas of no detected text. Colors represent the quality of detected text, with red meaning the lowest quality and yellow and green meaning progressively higher quality.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_result_t
quality_heatmapPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_result_get_quality_level()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_result_get_quality_level ( scanbotsdk_document_quality_analyzer_result_t * self,
scanbotsdk_document_quality_t ** quality_level )

Returns value of quality_level field of the given object. The returned pointers do NOT own the underlying object, caller must not free them.

Deprecated, please use quality instead, because it provides a more reliable result. Quality of the document, if found. The exact behavior of this value can be configured with the qualityThresholds and qualityIndices parameters.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_result_t
quality_levelPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_analyzer_run()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_run ( scanbotsdk_document_quality_analyzer_t * self,
scanbotsdk_image_t * image,
scanbotsdk_document_quality_analyzer_result_t ** result )

analyze document quality of the given image.

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_t method to be called on
imageThe image to analyze. The value must not be null.
resultPointer to a variable that will store the created instance of scanbotsdk_document_quality_analyzer_t
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_training_data_free()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_training_data_free ( scanbotsdk_document_quality_analyzer_training_data_t * object)

Frees the memory allocated for the instance of scanbotsdk_document_quality_analyzer_training_data_t. If null is passed, the function does nothing.

Parameters
objectPointer to the instance of scanbotsdk_document_quality_analyzer_training_data_t to be freed
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_analyzer_training_data_get_character_level_annotations()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_analyzer_training_data_get_character_level_annotations ( scanbotsdk_document_quality_analyzer_training_data_t * self,
scanbotsdk_character_level_annotations_t ** character_level_annotations )

Returns value of character_level_annotations field of the given object. The returned pointers do NOT own the underlying object, caller must not free them.

Character level annotations, contains information about each character in the document.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_analyzer_training_data_t
character_level_annotationsPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_assessment_t_to_string()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_assessment_t_to_string ( scanbotsdk_document_quality_assessment_t value,
const char ** result )

Returns the string representation of the given scanbotsdk_document_quality_assessment_t value.

The returned string doesn't need to be freed.

Parameters
valueThe value to be converted to string.
resultPointer to a variable that will store the string representation of the value.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_t_to_string()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_t_to_string ( scanbotsdk_document_quality_t value,
const char ** result )

Returns the string representation of the given scanbotsdk_document_quality_t value.

The returned string doesn't need to be freed.

Parameters
valueThe value to be converted to string.
resultPointer to a variable that will store the string representation of the value.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_threshold_create()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_threshold_create ( double symbol_quality,
double symbol_ratio,
scanbotsdk_document_quality_threshold_t ** result )

Creates a new instance of scanbotsdk_document_quality_threshold with given params and stores it in the location specified by the last argument.

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
symbol_qualitySymbol quality.
symbol_ratioSymbol ratio.
resultPointer to a variable that will store the created instance of scanbotsdk_document_quality_threshold_t
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_threshold_free()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_threshold_free ( scanbotsdk_document_quality_threshold_t * object)

Frees the memory allocated for the instance of scanbotsdk_document_quality_threshold_t. If null is passed, the function does nothing.

Parameters
objectPointer to the instance of scanbotsdk_document_quality_threshold_t to be freed
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_document_quality_threshold_get_symbol_quality()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_threshold_get_symbol_quality ( scanbotsdk_document_quality_threshold_t * self,
double * symbol_quality )

Returns value of symbol_quality field of the given object.

Symbol quality.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_threshold_t
symbol_qualityPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_document_quality_threshold_get_symbol_ratio()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_document_quality_threshold_get_symbol_ratio ( scanbotsdk_document_quality_threshold_t * self,
double * symbol_ratio )

Returns value of symbol_ratio field of the given object.

Symbol ratio.

Parameters
selfPointer to the instance of scanbotsdk_document_quality_threshold_t
symbol_ratioPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_process_by_tile_configuration_create()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_create ( bool enabled,
double min_processed_fraction,
double max_processed_fraction,
int min_number_of_required_symbols,
int tile_size,
scanbotsdk_process_by_tile_configuration_t ** result )

Creates a new instance of scanbotsdk_process_by_tile_configuration with given params and stores it in the location specified by the last argument.

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
enabledEnable processing by tiles.

Default is false

Parameters
min_processed_fractionAt least this fraction of the image will be processed, range is from 0 to 1. Decreasing this value below 1.0 can lead to faster processing but may result in less accurate prediction, as only a subset of the image tiles will be analyzed.

Default is 1

Parameters
max_processed_fractionAt most this fraction of the image will be processed, range is from 0 to 1. Decreasing this value below 1.0 can lead to faster processing but may result in less accurate prediction, as only a subset of the image tiles will be analyzed.

Default is 1

Parameters
min_number_of_required_symbolsIf this number of symbols is found and minProcessedFraction of the image is processed, the processing stops.

Default is 100

Parameters
tile_sizeImage will be processed in tiles of this size; will be ignored if image is small.

Default is 300

Parameters
resultPointer to a variable that will store the created instance of scanbotsdk_process_by_tile_configuration_t
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_process_by_tile_configuration_create_with_defaults()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_create_with_defaults ( scanbotsdk_process_by_tile_configuration_t ** result)

Creates a new instance of scanbotsdk_process_by_tile_configuration_t with given required params and stores it in the location specified by the last argument.

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
resultPointer to a variable that will store the created instance of scanbotsdk_process_by_tile_configuration_t
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_process_by_tile_configuration_free()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_free ( scanbotsdk_process_by_tile_configuration_t * object)

Frees the memory allocated for the instance of scanbotsdk_process_by_tile_configuration_t. If null is passed, the function does nothing.

Parameters
objectPointer to the instance of scanbotsdk_process_by_tile_configuration_t to be freed
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_process_by_tile_configuration_get_enabled()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_get_enabled ( scanbotsdk_process_by_tile_configuration_t * self,
bool * enabled )

Returns value of enabled field of the given object.

Enable processing by tiles.

Default is false

Parameters
selfPointer to the instance of scanbotsdk_process_by_tile_configuration_t
enabledPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_process_by_tile_configuration_get_max_processed_fraction()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_get_max_processed_fraction ( scanbotsdk_process_by_tile_configuration_t * self,
double * max_processed_fraction )

Returns value of max_processed_fraction field of the given object.

At most this fraction of the image will be processed, range is from 0 to 1. Decreasing this value below 1.0 can lead to faster processing but may result in less accurate prediction, as only a subset of the image tiles will be analyzed.

Default is 1

Parameters
selfPointer to the instance of scanbotsdk_process_by_tile_configuration_t
max_processed_fractionPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_process_by_tile_configuration_get_min_number_of_required_symbols()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_get_min_number_of_required_symbols ( scanbotsdk_process_by_tile_configuration_t * self,
int * min_number_of_required_symbols )

Returns value of min_number_of_required_symbols field of the given object.

If this number of symbols is found and minProcessedFraction of the image is processed, the processing stops.

Default is 100

Parameters
selfPointer to the instance of scanbotsdk_process_by_tile_configuration_t
min_number_of_required_symbolsPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_process_by_tile_configuration_get_min_processed_fraction()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_get_min_processed_fraction ( scanbotsdk_process_by_tile_configuration_t * self,
double * min_processed_fraction )

Returns value of min_processed_fraction field of the given object.

At least this fraction of the image will be processed, range is from 0 to 1. Decreasing this value below 1.0 can lead to faster processing but may result in less accurate prediction, as only a subset of the image tiles will be analyzed.

Default is 1

Parameters
selfPointer to the instance of scanbotsdk_process_by_tile_configuration_t
min_processed_fractionPointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_process_by_tile_configuration_get_tile_size()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_get_tile_size ( scanbotsdk_process_by_tile_configuration_t * self,
int * tile_size )

Returns value of tile_size field of the given object.

Image will be processed in tiles of this size; will be ignored if image is small.

Default is 300

Parameters
selfPointer to the instance of scanbotsdk_process_by_tile_configuration_t
tile_sizePointer to a variable that will store the value of the field.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered.

◆ scanbotsdk_process_by_tile_configuration_set_enabled()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_set_enabled ( scanbotsdk_process_by_tile_configuration_t * self,
bool enabled )

Sets value of enabled field of the given object.

Enable processing by tiles.

Default is false

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_process_by_tile_configuration_t, the field of which will be set
enabledThe value to be set.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_process_by_tile_configuration_set_max_processed_fraction()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_set_max_processed_fraction ( scanbotsdk_process_by_tile_configuration_t * self,
double max_processed_fraction )

Sets value of max_processed_fraction field of the given object.

At most this fraction of the image will be processed, range is from 0 to 1. Decreasing this value below 1.0 can lead to faster processing but may result in less accurate prediction, as only a subset of the image tiles will be analyzed.

Default is 1

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_process_by_tile_configuration_t, the field of which will be set
max_processed_fractionThe value to be set.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_process_by_tile_configuration_set_min_number_of_required_symbols()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_set_min_number_of_required_symbols ( scanbotsdk_process_by_tile_configuration_t * self,
int min_number_of_required_symbols )

Sets value of min_number_of_required_symbols field of the given object.

If this number of symbols is found and minProcessedFraction of the image is processed, the processing stops.

Default is 100

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_process_by_tile_configuration_t, the field of which will be set
min_number_of_required_symbolsThe value to be set.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_process_by_tile_configuration_set_min_processed_fraction()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_set_min_processed_fraction ( scanbotsdk_process_by_tile_configuration_t * self,
double min_processed_fraction )

Sets value of min_processed_fraction field of the given object.

At least this fraction of the image will be processed, range is from 0 to 1. Decreasing this value below 1.0 can lead to faster processing but may result in less accurate prediction, as only a subset of the image tiles will be analyzed.

Default is 1

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_process_by_tile_configuration_t, the field of which will be set
min_processed_fractionThe value to be set.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered

◆ scanbotsdk_process_by_tile_configuration_set_tile_size()

SBSDK_API scanbotsdk_error_code_t scanbotsdk_process_by_tile_configuration_set_tile_size ( scanbotsdk_process_by_tile_configuration_t * self,
int tile_size )

Sets value of tile_size field of the given object.

Image will be processed in tiles of this size; will be ignored if image is small.

Default is 300

As a rule if a function argument is a pointer to a scanbotsdk structure (scanbotsdk_..._t*) then the corresponding objects after function execution are left in valid but unspecified state, the caller is still responsible for freeing them. Exceptions are scanbotsdk_image_t*, scanbotdk_random_access_source_t* (if applicable) which are guaranteed to be in the original state.

Parameters
selfPointer to the instance of scanbotsdk_process_by_tile_configuration_t, the field of which will be set
tile_sizeThe value to be set.
Returns
: Error code, SCANBOTSDK_OK if no errors were encountered