camera_enable_image_event()

Enable the final image data event.

Synopsis:

#include <camera/camera_api.h>
 
camera_error_t camera_enable_image_event(camera_handle_t handle,                 
                                         camera_eventmode_t eventmode,                 
                                         camera_eventkey_t *key,                 
                                         struct sigevent *event)

Since:

BlackBerry 10.0.0

Arguments:

handle

The handle returned by a call to the camera_open() function.

eventmode

The event buffering mode as a camera_eventmode_t value.

key

A pointer to a returned camera_eventkey_t value. This argument is required for subsequent function calls to identify the proper event.

event

A pointer to a struct sigevent. The struct sigevent must be initialized by the caller. This is the struct sigevent that will be delivered when a still image is available to retrieve using camera_get_image_buffers().

Library:

libcamapi (For the qcc command, use the -l camapi option to link against this library)

Description:

Use this function to enable the image event. The image event is delivered when the final image data is available. You can then retrieve the image buffer using camera_get_image_buffers(). This is the same image buffer that is delivered to your image_callback function registered when you started photo capture using camera_take_photo(), camera_take_burst(), or camera_start_burst().

Call this function when you are using the Camera API in event mode. For more information, see scope="peer">About event mode.

Use camera_disable_event() to disable an event when you no longer require image events to be delivered.

Returns:

CAMERA_EOK when the function successfully completes, otherwise another camera_error_t value that provides the reason that the call failed.

Last modified: 2014-06-24



Got questions about leaving a comment? Get answers from our Disqus FAQ.

comments powered by Disqus