Functions | |
int | _zbar_process_image (zbar_processor_t *proc, zbar_image_t *img) |
int | _zbar_processor_handle_input (zbar_processor_t *proc, int input) |
static int | proc_enter (zbar_processor_t *proc) |
static int | proc_leave (zbar_processor_t *proc) |
static int | proc_open (zbar_processor_t *proc) |
int | zbar_process_image (zbar_processor_t *proc, zbar_image_t *img) |
int | zbar_process_one (zbar_processor_t *proc, int timeout) |
zbar_processor_t * | zbar_processor_create (int threaded) |
constructor. More... | |
void | zbar_processor_destroy (zbar_processor_t *proc) |
int | zbar_processor_force_format (zbar_processor_t *proc, unsigned long input, unsigned long output) |
const zbar_symbol_set_t * | zbar_processor_get_results (const zbar_processor_t *proc) |
void * | zbar_processor_get_userdata (const zbar_processor_t *proc) |
int | zbar_processor_init (zbar_processor_t *proc, const char *dev, int enable_display) |
int | zbar_processor_is_visible (zbar_processor_t *proc) |
int | zbar_processor_request_interface (zbar_processor_t *proc, int ver) |
int | zbar_processor_request_iomode (zbar_processor_t *proc, int iomode) |
int | zbar_processor_request_size (zbar_processor_t *proc, unsigned width, unsigned height) |
int | zbar_processor_set_active (zbar_processor_t *proc, int active) |
int | zbar_processor_set_config (zbar_processor_t *proc, zbar_symbol_type_t sym, zbar_config_t cfg, int val) |
zbar_image_data_handler_t * | zbar_processor_set_data_handler (zbar_processor_t *proc, zbar_image_data_handler_t *handler, const void *userdata) |
void | zbar_processor_set_userdata (zbar_processor_t *proc, void *userdata) |
int | zbar_processor_set_visible (zbar_processor_t *proc, int visible) |
int | zbar_processor_user_wait (zbar_processor_t *proc, int timeout) |
int _zbar_process_image | ( | zbar_processor_t * | proc, |
zbar_image_t * | img | ||
) |
References __func__, _zbar_image_swap_symbols(), _zbar_mutex_lock, _zbar_mutex_unlock, _zbar_processor_invalidate(), _zbar_processor_notify(), _zbar_verbosity, err_capture(), err_copy(), EVENT_OUTPUT, format, fourcc, SEV_ERROR, zbar::ZBAR_ERR_UNSUPPORTED, zbar_get_addon_name(), zbar_get_symbol_name(), zbar_image_convert(), zbar_image_destroy(), zbar_image_first_symbol(), zbar_image_get_data(), zbar_image_get_format(), zbar_image_get_height(), zbar_image_get_width(), zbar_image_scanner_get_results(), zbar_image_scanner_recycle_image(), zbar_image_write(), zbar_scan_image(), zbar_symbol_get_count(), zbar_symbol_get_data(), zbar_symbol_get_loc_size(), zbar_symbol_get_quality(), zbar_symbol_get_type(), zbar_symbol_next(), zbar_symbol_set_ref(), zbar_window_draw(), and zprintf.
Referenced by _zbar_processor_handle_input(), proc_video_handler(), proc_wait_unthreaded(), and zbar_process_image().
int _zbar_processor_handle_input | ( | zbar_processor_t * | proc, |
int | input | ||
) |
References __func__, _zbar_event_trigger(), _zbar_event_wait(), _zbar_mutex_lock, _zbar_mutex_unlock, _zbar_process_image(), _zbar_processor_close(), _zbar_processor_input_wait(), _zbar_processor_lock(), _zbar_processor_notify(), _zbar_processor_set_visible(), _zbar_processor_unlock(), zbar_thread_s::activity, err_capture(), EVENT_CANCELED, EVENT_INPUT, EVENT_OUTPUT, zbar_thread_s::notify, proc, proc_open(), zbar_thread_s::running, SEV_WARNING, zbar_thread_s::started, zbar::ZBAR_ERR_CLOSED, zbar_image_destroy(), zbar_video_next_image(), zbar_window_get_overlay(), zbar_window_set_overlay(), and zprintf.
Referenced by win_handle_event(), and x_handle_event().
|
inlinestatic |
References _zbar_mutex_lock, and _zbar_processor_lock().
Referenced by zbar_process_image(), zbar_process_one(), zbar_processor_force_format(), zbar_processor_get_results(), zbar_processor_is_visible(), zbar_processor_request_interface(), zbar_processor_request_iomode(), zbar_processor_request_size(), zbar_processor_set_active(), zbar_processor_set_config(), zbar_processor_set_data_handler(), zbar_processor_set_visible(), and zbar_processor_user_wait().
|
inlinestatic |
References _zbar_mutex_unlock, and _zbar_processor_unlock().
Referenced by zbar_process_image(), zbar_process_one(), zbar_processor_force_format(), zbar_processor_get_results(), zbar_processor_init(), zbar_processor_is_visible(), zbar_processor_request_interface(), zbar_processor_request_iomode(), zbar_processor_request_size(), zbar_processor_set_active(), zbar_processor_set_config(), zbar_processor_set_data_handler(), zbar_processor_set_visible(), and zbar_processor_user_wait().
|
inlinestatic |
References _zbar_processor_open(), scan_image::height, scan_image::width, zbar_video_get_height(), and zbar_video_get_width().
Referenced by _zbar_processor_handle_input(), and zbar_processor_init().
int zbar_process_image | ( | zbar_processor_t * | proc, |
zbar_image_t * | img | ||
) |
References _zbar_mutex_lock, _zbar_mutex_unlock, _zbar_process_image(), _zbar_processor_set_size(), proc_enter(), proc_leave(), zbar_image_get_height(), zbar_image_get_width(), and zbar_image_scanner_enable_cache().
Referenced by main(), processor_process_image(), and scan_image().
int zbar_process_one | ( | zbar_processor_t * | proc, |
int | timeout | ||
) |
References __func__, _zbar_mutex_lock, _zbar_mutex_unlock, _zbar_processor_wait(), _zbar_timer_init(), err_capture(), EVENT_OUTPUT, proc_enter(), proc_leave(), SEV_ERROR, zbar::ZBAR_ERR_INVALID, and zbar_processor_set_active().
Referenced by processor_process_one().
zbar_processor_t* zbar_processor_create | ( | int | threaded | ) |
constructor.
if threaded is set and threading is available the processor will spawn threads where appropriate to avoid blocking and improve responsiveness
References _zbar_mutex_init, _zbar_processor_init(), err_init(), proc, zbar_image_scanner_create(), and ZBAR_MOD_PROCESSOR.
Referenced by main(), zbar::Processor::Processor(), and processor_new().
void zbar_processor_destroy | ( | zbar_processor_t * | proc | ) |
References _zbar_event_destroy(), _zbar_mutex_destroy, _zbar_processor_cleanup(), err_cleanup(), proc_waiter_s::next, proc_waiter_s::notify, zbar_image_scanner_destroy(), and zbar_processor_init().
Referenced by main(), and processor_dealloc().
int zbar_processor_force_format | ( | zbar_processor_t * | proc, |
unsigned long | input, | ||
unsigned long | output | ||
) |
References proc_enter(), and proc_leave().
Referenced by main().
const zbar_symbol_set_t* zbar_processor_get_results | ( | const zbar_processor_t * | proc | ) |
References proc_enter(), proc_leave(), and zbar_symbol_set_ref().
Referenced by processor_get_results().
void* zbar_processor_get_userdata | ( | const zbar_processor_t * | proc | ) |
References _zbar_mutex_lock, _zbar_mutex_unlock, and userdata.
int zbar_processor_init | ( | zbar_processor_t * | proc, |
const char * | dev, | ||
int | enable_display | ||
) |
References __func__, _zbar_mutex_lock, _zbar_mutex_unlock, _zbar_processor_close(), _zbar_processor_lock(), _zbar_thread_start(), _zbar_thread_stop(), err_capture(), err_copy(), fprintf(), proc_leave(), proc_open(), SEV_ERROR, SEV_FATAL, zbar::ZBAR_ERR_NOMEM, zbar::ZBAR_ERR_SYSTEM, zbar::ZBAR_ERR_UNSUPPORTED, zbar_negotiate_format(), zbar_processor_set_active(), zbar_video_create(), zbar_video_destroy(), zbar_video_get_fd(), zbar_video_init(), zbar_video_open(), zbar_video_request_interface(), zbar_video_request_iomode(), zbar_video_request_size(), zbar_window_create(), zbar_window_destroy(), and zprintf.
Referenced by main(), processor_init_(), and zbar_processor_destroy().
int zbar_processor_is_visible | ( | zbar_processor_t * | proc | ) |
References proc_enter(), proc_leave(), and read_one::visible.
Referenced by processor_get_bool(), and scan_image().
int zbar_processor_request_interface | ( | zbar_processor_t * | proc, |
int | ver | ||
) |
References proc_enter(), and proc_leave().
Referenced by main().
int zbar_processor_request_iomode | ( | zbar_processor_t * | proc, |
int | iomode | ||
) |
References proc_enter(), and proc_leave().
Referenced by main().
int zbar_processor_request_size | ( | zbar_processor_t * | proc, |
unsigned | width, | ||
unsigned | height | ||
) |
References scan_image::height, proc_enter(), proc_leave(), and scan_image::width.
Referenced by main().
int zbar_processor_set_active | ( | zbar_processor_t * | proc, |
int | active | ||
) |
References __func__, _zbar_event_trigger(), _zbar_mutex_lock, _zbar_mutex_unlock, _zbar_processor_enable(), _zbar_processor_invalidate(), err_capture(), err_copy(), proc_enter(), proc_leave(), SEV_ERROR, zbar::ZBAR_ERR_INVALID, zbar_image_scanner_enable_cache(), zbar_video_enable(), and zbar_window_draw().
Referenced by main(), processor_set_bool(), zbar_process_one(), and zbar_processor_init().
int zbar_processor_set_config | ( | zbar_processor_t * | proc, |
zbar_symbol_type_t | sym, | ||
zbar_config_t | cfg, | ||
int | val | ||
) |
References proc_enter(), proc_leave(), and zbar_image_scanner_set_config().
Referenced by processor_set_config().
zbar_image_data_handler_t* zbar_processor_set_data_handler | ( | zbar_processor_t * | proc, |
zbar_image_data_handler_t * | handler, | ||
const void * | userdata | ||
) |
References proc_enter(), proc_leave(), result, and userdata.
Referenced by main(), processor_clear(), and processor_set_data_handler().
References _zbar_mutex_lock, _zbar_mutex_unlock, and userdata.
Referenced by processor_clear(), and processor_new().
int zbar_processor_set_visible | ( | zbar_processor_t * | proc, |
int | visible | ||
) |
References __func__, _zbar_mutex_lock, _zbar_mutex_unlock, _zbar_processor_set_size(), _zbar_processor_set_visible(), err_capture(), proc_enter(), proc_leave(), SEV_ERROR, zbar::ZBAR_ERR_INVALID, zbar_video_get_height(), and zbar_video_get_width().
Referenced by main(), and processor_set_bool().
int zbar_processor_user_wait | ( | zbar_processor_t * | proc, |
int | timeout | ||
) |
References __func__, _zbar_mutex_lock, _zbar_mutex_unlock, _zbar_processor_wait(), _zbar_timer_init(), err_capture(), EVENT_INPUT, proc_enter(), proc_leave(), SEV_WARNING, and zbar::ZBAR_ERR_CLOSED.
Referenced by input_wait(), main(), processor_user_wait(), and scan_image().