summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeongmo Yang <jm80.yang@samsung.com>2022-03-23 13:12:54 +0900
committerJeongmo Yang <jm80.yang@samsung.com>2022-06-21 14:30:12 +0900
commit4f924e50fb4b49aacb61efbd6c8358516e6f586b (patch)
tree376be673f7daff0ee1eab4c7cbb5a6754804355f
parent0176775a6715f2c2e9c994740effb65eb5fe055c (diff)
downloadcamera-4f924e50fb4b49aacb61efbd6c8358516e6f586b.tar.gz
camera-4f924e50fb4b49aacb61efbd6c8358516e6f586b.tar.bz2
camera-4f924e50fb4b49aacb61efbd6c8358516e6f586b.zip
[ACR-1688] Add new APIs for network camera
- New API list : camera_create_network() : camera_device_manager_initialize() : camera_device_manager_deinitialize() : camera_device_manager_foreach_supported_device() : camera_device_manager_add_device_connection_changed_cb() : camera_device_manager_remove_device_connection_changed_cb() : camera_is_supported_extra_preview() : camera_set_extra_preview_cb() : camera_unset_extra_preview_cb() : camera_set_extra_preview_stream_format() : camera_get_extra_preview_stream_format() : camera_attr_set_extra_preview_bitrate() : camera_attr_get_extra_preview_bitrate() : camera_attr_set_extra_preview_gop_interval() : camera_attr_get_extra_preview_gop_interval() : camera_attr_get_preview_frame_rotation() [Version] 0.4.80 [Issue Type] New feature Change-Id: I7686cd0de15679e51efcd69c297ebac1239408e9 Signed-off-by: Jeongmo Yang <jm80.yang@samsung.com>
-rw-r--r--include/camera.h647
-rw-r--r--include/camera_internal.h295
-rw-r--r--include/camera_private.h2
-rw-r--r--packaging/capi-media-camera.spec4
-rw-r--r--src/camera.c675
-rw-r--r--src/camera_internal.c456
-rw-r--r--test/camera_test.c62
-rw-r--r--test_headless/camera_test_headless.c61
8 files changed, 1152 insertions, 1050 deletions
diff --git a/include/camera.h b/include/camera.h
index a59999c..b338e1b 100644
--- a/include/camera.h
+++ b/include/camera.h
@@ -199,6 +199,16 @@ typedef enum {
} camera_flash_state_e;
/**
+ * @brief Enumeration for the device type.
+ * @since_tizen 7.0
+ */
+typedef enum {
+ CAMERA_DEVICE_TYPE_BUILTIN = 0, /**< Built-in camera */
+ CAMERA_DEVICE_TYPE_USB, /**< USB camera */
+ CAMERA_DEVICE_TYPE_NETWORK /**< Network camera */
+} camera_device_type_e;
+
+/**
* @brief The structure type of the image data.
* @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
*/
@@ -299,6 +309,12 @@ typedef void *camera_display_h;
#endif
/**
+ * @brief The Camera device manager handle.
+ * @since_tizen 7.0
+ */
+typedef void *camera_device_manager_h;
+
+/**
* @}
*/
@@ -704,6 +720,35 @@ typedef void (*camera_error_cb)(camera_error_e error, camera_state_e current_sta
typedef void (*camera_face_detected_cb)(camera_detected_face_s *faces, int count, void *user_data);
/**
+ * @brief Called when the connection state of a camera device was changed.
+ * @since_tizen 7.0
+ * @param[in] type The device type
+ * @param[in] device The device index
+ * @param[in] name The device name
+ * @param[in] id The device ID
+ * @param[in] extra_preview_stream_num The number of extra preview stream
+ * @param[in] is_connected The state of device connection: (@c true = connected, @c false = disconnected)
+ * @param[in] user_data The user data passed from the callback registration function
+ * @see camera_device_manager_add_device_connection_changed_cb()
+ * @see camera_device_manager_remove_device_connection_changed_cb()
+ */
+typedef void (*camera_device_connection_changed_cb)(camera_device_type_e type, camera_device_e device,
+ const char *name, const char *id, int extra_preview_stream_num, bool is_connected, void *user_data);
+
+/**
+ * @brief Called when the extra preview frame is delivered from the camera device.
+ * @since_tizen 7.0
+ * @param[in] frame The reference pointer to extra preview stream data
+ * @param[in] stream_id The ID of the preview stream
+ * @param[in] user_data The user data passed from the callback registration function
+ * @pre camera_start_preview() will invoke this callback function if you register this callback using camera_set_extra_preview_cb().
+ * @see camera_start_preview()
+ * @see camera_set_extra_preview_cb()
+ * @see camera_unset_extra_preview_cb()
+ */
+typedef void (*camera_extra_preview_cb)(camera_preview_data_s *frame, int stream_id, void *user_data);
+
+/**
* @}
*/
@@ -759,6 +804,22 @@ typedef bool (*camera_supported_capture_format_cb)(camera_pixel_format_e format,
typedef bool (*camera_supported_preview_format_cb)(camera_pixel_format_e format, void *user_data);
/**
+ * @brief Called once for the each supported device.
+ * @since_tizen 7.0
+ * @param[in] type The device type
+ * @param[in] device The device index
+ * @param[in] name The device name
+ * @param[in] id The device ID
+ * @param[in] extra_preview_stream_num The number of extra preview stream
+ * @param[in] user_data The user data passed from the foreach function
+ * @return @c true to continue with the next iteration of the loop, \n otherwise @c false to break out of the loop
+ * @pre camera_foreach_supported_device() will invoke this callback.
+ * @see camera_foreach_supported_device()
+ */
+typedef bool (*camera_supported_device_cb)(camera_device_type_e type, camera_device_e device,
+ const char *name, const char *id, int extra_preview_stream_num, void *user_data);
+
+/**
* @}
*/
@@ -781,11 +842,11 @@ typedef bool (*camera_supported_preview_format_cb)(camera_pixel_format_e format,
* @param[out] camera A newly returned handle to the camera
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_OUT_OF_MEMORY Out of memory
* @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @post If it succeeds, the camera state will be #CAMERA_STATE_CREATED.
*
* @see camera_destroy()
@@ -803,11 +864,11 @@ int camera_create(camera_device_e device, camera_h *camera);
* @param[in] device The hardware camera to access
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_OUT_OF_MEMORY Out of memory
* @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED.
* @post If it succeeds, the camera attributes and settings will be reset.
@@ -824,16 +885,130 @@ int camera_change_device(camera_h camera, camera_device_e device);
* @param[in] camera The handle to the camera
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @see camera_create()
+ * @see camera_create_network()
*/
int camera_destroy(camera_h camera);
/**
+ * @brief Creates a new camera handle for controlling a network camera.
+ * @since_tizen 7.0
+ * @remarks A @a camera must be released using camera_destroy().
+ * @param[in] device The network camera to access
+ * @param[out] camera A newly returned handle to the camera
+ * @return @c 0 on success, otherwise a negative error value
+ * @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
+ * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #CAMERA_ERROR_OUT_OF_MEMORY Out of memory
+ * @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
+ * @post If it succeeds, the camera state will be #CAMERA_STATE_CREATED.
+ * @see camera_destroy()
+ */
+int camera_create_network(camera_device_e device, camera_h *camera);
+
+/**
+ * @brief Initializes a camera device manager.
+ * @since_tizen 7.0
+ * @remarks A @a manager must be released with camera_device_manager_deinitialize().
+ * @param[out] manager A newly returned handle to the camera device manager
+ * @return @c 0 on success, otherwise a negative error value
+ * @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
+ * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #CAMERA_ERROR_OUT_OF_MEMORY Out of memory
+ * @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
+ * @see camera_device_manager_deinitialize()
+ */
+int camera_device_manager_initialize(camera_device_manager_h *manager);
+
+/**
+ * @brief Deinitializes the camera device manager handle.
+ * @since_tizen 7.0
+ * @param[in] manager The handle to the camera device manager
+ * @return @c 0 on success, otherwise a negative error value
+ * @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
+ * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
+ * @see camera_device_manager_initialize()
+ */
+int camera_device_manager_deinitialize(camera_device_manager_h manager);
+
+/**
+ * @}
+ */
+
+/**
+ * @addtogroup CAPI_MEDIA_CAMERA_CAPABILITY_MODULE
+ * @{
+ */
+
+/**
+ * @brief Retrieves all supported devices by invoking the callback function once for each supported device.
+ * @since_tizen 7.0
+ * @param[in] manager The handle to the camera device manager
+ * @param[in] callback The callback function to register
+ * @param[in] user_data The user data to be passed to the callback function
+ * @return @c 0 on success, otherwise a negative error value
+ * @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
+ * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
+ * @post This function invokes camera_supported_device_cb() repeatedly to retrieve each supported device.
+ * @see camera_supported_device_cb()
+ * @see camera_device_manager_initialize()
+ * @see camera_device_manager_deinitialize()
+ */
+int camera_device_manager_foreach_supported_device(camera_device_manager_h manager, camera_supported_device_cb callback, void *user_data);
+
+/**
+ * @}
+ */
+
+/**
+ * @addtogroup CAPI_MEDIA_CAMERA_MODULE
+ * @{
+ */
+
+/**
+ * @brief Adds a callback function to be called when the connection state of camera device is changed.
+ * @since_tizen 7.0
+ * @param[in] manager The handle to the camera device manager
+ * @param[in] callback The callback function to register
+ * @param[in] user_data The user data to be passed to the callback function
+ * @param[out] cb_id The id of registered callback
+ * @return @c 0 on success, otherwise a negative error value
+ * @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
+ * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
+ * @post camera_device_connection_changed_cb() will be invoked when the connection state of camera device is changed.
+ * @see camera_device_manager_remove_device_connection_changed_cb()
+ * @see camera_device_connection_changed_cb()
+ */
+int camera_device_manager_add_device_connection_changed_cb(camera_device_manager_h manager, camera_device_connection_changed_cb callback, void *user_data, int *cb_id);
+
+/**
+ * @brief Removes the callback function.
+ * @since_tizen 7.0
+ * @param[in] manager The handle to the camera device manager
+ * @param[in] cb_id The id of registered callback
+ * @return @c 0 on success, otherwise a negative error value
+ * @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
+ * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
+ * @see camera_device_manager_add_device_changed_cb()
+ */
+int camera_device_manager_remove_device_connection_changed_cb(camera_device_manager_h manager, int cb_id);
+
+/**
* @brief Starts capturing and drawing preview frames on the screen.
*
* @since_tizen @if MOBILE 2.3 @elseif WEARABLE 2.3.1 @endif
@@ -842,6 +1017,7 @@ int camera_destroy(camera_h camera);
* @param[in] camera The handle to the camera
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_RESOURCE_CONFLICT Resource conflict error
@@ -849,7 +1025,6 @@ int camera_destroy(camera_h camera);
* @retval #CAMERA_ERROR_DEVICE_BUSY The device is being used in another application or is performing other operations
* @retval #CAMERA_ERROR_DEVICE_NOT_FOUND No camera device
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_CAPTURED.\n
* You must set the display handle. \n
@@ -882,11 +1057,11 @@ int camera_start_preview(camera_h camera);
* @param[in] camera The handle to the camera
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_PREVIEW.
* @post The camera state will be #CAMERA_STATE_CREATED.
@@ -913,11 +1088,11 @@ int camera_stop_preview(camera_h camera);
* @param[in] user_data The user data
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_PREVIEW. \n
* If needed, modify capture resolution(camera_set_capture_resolution()),
@@ -957,11 +1132,11 @@ int camera_start_capture(camera_h camera, camera_capturing_cb capturing_cb, came
* @param[in] user_data The user data
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post If it succeeds the camera state will be #CAMERA_STATE_CAPTURED.
*
@@ -982,11 +1157,11 @@ int camera_start_continuous_capture(camera_h camera, int count, int interval, ca
* @param[in] camera The handle to the camera
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_PREVIEW.
*
@@ -1002,9 +1177,9 @@ int camera_stop_continuous_capture(camera_h camera);
* @param[out] state The current state of the camera
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_create()
* @see camera_start_preview()
@@ -1024,11 +1199,11 @@ int camera_get_state(camera_h camera, camera_state_e *state);
* @param[in] continuous The status of continuous focusing
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_PREVIEW.
* @post The camera focus state will be #CAMERA_FOCUS_STATE_ONGOING.
@@ -1048,11 +1223,11 @@ int camera_start_focusing(camera_h camera, bool continuous);
* @param[in] camera The handle to the camera
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_PREVIEW.
*
@@ -1077,11 +1252,11 @@ int camera_cancel_focusing(camera_h camera);
* @param[in] display The display handle from #GET_DISPLAY
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED.
*
@@ -1102,10 +1277,10 @@ int camera_set_display(camera_h camera, camera_display_type_e type, camera_displ
* @param[in] height The preview height
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
*
@@ -1124,9 +1299,9 @@ int camera_set_preview_resolution(camera_h camera, int width, int height);
* @param[out] height The preview height
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_set_preview_resolution()
* @see camera_foreach_supported_preview_resolution()
@@ -1143,9 +1318,9 @@ int camera_get_preview_resolution(camera_h camera, int *width, int *height);
* @param[out] height The preview height
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_set_preview_resolution()
* @see camera_foreach_supported_preview_resolution()
@@ -1168,11 +1343,11 @@ int camera_get_recommended_preview_resolution(camera_h camera, int *width, int *
*
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Not preview state
* @retval #CAMERA_ERROR_INVALID_OPERATION Not supported this feature
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be #CAMERA_STATE_PREVIEW.
*
@@ -1191,9 +1366,9 @@ int camera_start_face_detection(camera_h camera, camera_face_detected_cb callbac
* @param[in] camera The handle to the camera
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre This should be called after face detection is started.
*
@@ -1219,9 +1394,9 @@ int camera_stop_face_detection(camera_h camera);
* @param[in] camera The handle to the camera
* @return @c true on supported, otherwise false
* @exception #CAMERA_ERROR_NONE Successful
+ * @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @exception #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @exception #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
*
*/
bool camera_is_supported_continuous_capture(camera_h camera);
@@ -1235,9 +1410,9 @@ bool camera_is_supported_continuous_capture(camera_h camera);
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function invokes camera_supported_preview_resolution_cb() repeatedly to retrieve each supported preview resolution.
*
@@ -1266,11 +1441,11 @@ int camera_foreach_supported_preview_resolution(camera_h camera, camera_supporte
* @param[in] rotation The display rotation
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_INVALID_OPERATION Display type is incorrect
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_start_preview()
* @see camera_get_display_rotation()
@@ -1286,9 +1461,9 @@ int camera_set_display_rotation(camera_h camera, camera_rotation_e rotation);
* @param[out] rotation The display rotation
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_set_display_rotation()
*/
@@ -1303,11 +1478,11 @@ int camera_get_display_rotation(camera_h camera, camera_rotation_e *rotation);
* @param[in] flip The display flip
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_INVALID_OPERATION Display type is incorrect
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_get_display_flip()
*/
@@ -1322,9 +1497,9 @@ int camera_set_display_flip(camera_h camera, camera_flip_e flip);
* @param[out] flip The display flip
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_set_display_flip()
*/
@@ -1340,9 +1515,9 @@ int camera_get_display_flip(camera_h camera, camera_flip_e *flip);
*
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_is_display_visible()
*/
@@ -1358,9 +1533,9 @@ int camera_set_display_visible(camera_h camera, bool visible);
*
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_set_display_visible()
*/
@@ -1376,9 +1551,9 @@ int camera_is_display_visible(camera_h camera, bool *visible);
*
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_get_display_mode()
*/
@@ -1394,9 +1569,9 @@ int camera_set_display_mode(camera_h camera, camera_display_mode_e mode);
*
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_set_display_mode()
*/
@@ -1445,10 +1620,10 @@ int camera_get_display_reuse_hint(camera_h camera, bool *hint);
* @param[in] height The capture height
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
* @see camera_start_capture()
@@ -1465,9 +1640,9 @@ int camera_set_capture_resolution(camera_h camera, int width, int height);
* @param[out] height The capture height
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_set_capture_resolution()
* @see camera_foreach_supported_capture_resolution()
@@ -1492,9 +1667,9 @@ int camera_get_capture_resolution(camera_h camera, int *width, int *height);
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function invokes camera_supported_capture_resolution_cb() repeatedly to retrieve each supported capture resolution.
* @see camera_set_capture_resolution()
@@ -1521,10 +1696,10 @@ int camera_foreach_supported_capture_resolution(camera_h camera, camera_supporte
* @param[out] format The format of the image to be captured
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
* @see camera_start_capture()
@@ -1541,9 +1716,9 @@ int camera_set_capture_format(camera_h camera, camera_pixel_format_e format);
* @param[out] format The format of the image to be captured
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_set_capture_format()
* @see camera_foreach_supported_capture_format()
@@ -1568,9 +1743,9 @@ int camera_get_capture_format(camera_h camera, camera_pixel_format_e *format);
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function invokes camera_supported_capture_format_cb() repeatedly to retrieve each supported capture format.
* @see camera_set_capture_format()
@@ -1596,10 +1771,10 @@ int camera_foreach_supported_capture_format(camera_h camera, camera_supported_ca
* @param[in] format The preview data format
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED.
* @see camera_start_preview()
@@ -1615,9 +1790,9 @@ int camera_set_preview_format(camera_h camera, camera_pixel_format_e format);
* @param[out] format The preview data format
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_set_preview_format()
* @see camera_foreach_supported_preview_format()
@@ -1631,9 +1806,9 @@ int camera_get_preview_format(camera_h camera, camera_pixel_format_e *format);
* @param[out] facing_direction The facing direction of camera module
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
*/
int camera_get_facing_direction(camera_h camera, camera_facing_direction_e *facing_direction);
@@ -1645,15 +1820,92 @@ int camera_get_facing_direction(camera_h camera, camera_facing_direction_e *faci
* @param[out] state The current flash state
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @see camera_attr_set_flash_mode()
* @see camera_attr_get_flash_mode()
*/
int camera_get_flash_state(camera_device_e device, camera_flash_state_e *state);
/**
+ * @brief Sets a callback function to be called for extra preview frames.
+ * @since_tizen 7.0
+ * @param[in] camera The handle to the camera
+ * @param[in] callback The callback function to be registered
+ * @param[in] user_data The user data to be passed to the callback function
+ * @return @c 0 on success, otherwise a negative error value
+ * @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
+ * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
+ * @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
+ * @see camera_start_preview()
+ * @see camera_unset_extra_preview_cb()
+ * @see camera_extra_preview_cb()
+ */
+int camera_set_extra_preview_cb(camera_h camera, camera_extra_preview_cb callback, void *user_data);
+
+/**
+ * @brief Unsets the callback function.
+ * @since_tizen 7.0
+ * @param[in] camera The handle to the camera
+ * @return @c 0 on success, otherwise a negative error value
+ * @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
+ * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
+ * @see camera_set_extra_preview_cb()
+ */
+int camera_unset_extra_preview_cb(camera_h camera);
+
+/**
+ * @brief Sets the extra preview stream format.
+ * @since_tizen 7.0
+ * @param[in] camera The handle to the camera
+ * @param[in] stream_id The id of extra preview stream
+ * @param[in] pixel_format The pixel format of extra preview stream
+ * @param[in] width The width of extra preview stream
+ * @param[in] height The height of extra preview stream
+ * @param[in] fps The fps of extra preview stream
+ * @return @c 0 on success, otherwise a negative error value
+ * @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
+ * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #CAMERA_ERROR_INVALID_STATE Invalid state
+ * @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
+ * @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
+ * @see camera_start_preview()
+ * @see camera_set_extra_preview_cb()
+ * @see camera_unset_extra_preview_cb()
+ * @see camera_get_extra_preview_stream_format()
+ */
+int camera_set_extra_preview_stream_format(camera_h camera, int stream_id, camera_pixel_format_e pixel_format, int width, int height, int fps);
+
+/**
+ * @brief Gets the extra preview stream format.
+ * @since_tizen 7.0
+ * @param[in] camera The handle to the camera
+ * @param[in] stream_id The id of extra preview stream
+ * @param[out] pixel_format The pixel format of extra preview stream
+ * @param[out] width The width of extra preview stream
+ * @param[out] height The height of extra preview stream
+ * @param[out] fps The fps of extra preview stream
+ * @return @c 0 on success, otherwise a negative error value
+ * @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
+ * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #CAMERA_ERROR_INVALID_STATE Invalid state
+ * @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
+ * @pre The camera state must be set to #CAMERA_STATE_PREVIEW.
+ * @see camera_start_preview()
+ * @see camera_set_extra_preview_cb()
+ * @see camera_unset_extra_preview_cb()
+ * @see camera_set_extra_preview_stream_format()
+ */
+int camera_get_extra_preview_stream_format(camera_h camera, int stream_id, camera_pixel_format_e *pixel_format, int *width, int *height, int *fps);
+
+/**
* @}
*/
@@ -1670,9 +1922,9 @@ int camera_get_flash_state(camera_device_e device, camera_flash_state_e *state);
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function invokes camera_supported_preview_format_cb() repeatedly to retrieve each supported preview format.
* @see camera_set_preview_format()
@@ -1689,9 +1941,9 @@ int camera_foreach_supported_preview_format(camera_h camera, camera_supported_pr
* @param[in] camera The handle to the camera
* @return @c true if supported, otherwise @c false
* @exception #CAMERA_ERROR_NONE Successful
+ * @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @exception #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @exception #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @see camera_start_face_detection()
* @see camera_stop_face_detection()
*/
@@ -1706,9 +1958,9 @@ bool camera_is_supported_face_detection(camera_h camera);
* @param[in] camera The handle to the camera
* @return @c true if supported, otherwise @c false
* @exception #CAMERA_ERROR_NONE Successful
+ * @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @exception #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @exception #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
*/
bool camera_is_supported_zero_shutter_lag(camera_h camera);
@@ -1721,9 +1973,9 @@ bool camera_is_supported_zero_shutter_lag(camera_h camera);
* @param[out] device_count The device count
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
*/
int camera_get_device_count(camera_h camera, int *device_count);
@@ -1736,14 +1988,26 @@ int camera_get_device_count(camera_h camera, int *device_count);
* @param[in] camera The handle to the camera
* @return @c true if supported, otherwise @c false
* @exception #CAMERA_ERROR_NONE Successful
+ * @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @exception #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @exception #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
*
*/
bool camera_is_supported_media_packet_preview_cb(camera_h camera);
/**
+ * @brief Gets the extra preview feature's supported state.
+ * @ingroup CAPI_MEDIA_CAMERA_CAPABILITY_MODULE
+ * @since_tizen 7.0
+ * @remarks The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section.
+ * @param[in] camera The handle to the camera
+ * @return @c true if supported, otherwise @c false
+ * @exception #CAMERA_ERROR_NONE Successful
+ * @exception #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
+ */
+bool camera_is_supported_extra_preview(camera_h camera);
+
+/**
* @}
*/
@@ -1771,9 +2035,9 @@ bool camera_is_supported_media_packet_preview_cb(camera_h camera);
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre Before 4.0 : The camera state must be set to #CAMERA_STATE_CREATED.\n
* Since 4.0 : The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
@@ -1789,9 +2053,9 @@ int camera_set_preview_cb(camera_h camera, camera_preview_cb callback, void *use
* @param[in] camera The handle to the camera
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_set_preview_cb()
*/
@@ -1812,9 +2076,9 @@ int camera_unset_preview_cb(camera_h camera);
* @param[in] user_data The user data to be passed to the callback function
* @return 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera's state should be #CAMERA_STATE_CREATED.
* @see camera_start_preview()
@@ -1829,9 +2093,9 @@ int camera_set_media_packet_preview_cb(camera_h camera, camera_media_packet_prev
* @param[in] camera The handle to the camera
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_set_media_packet_preview_cb()
*/
@@ -1845,9 +2109,9 @@ int camera_unset_media_packet_preview_cb(camera_h camera);
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function will invoke camera_state_changed_cb() when the camera state changes.
* @see camera_unset_state_changed_cb()
@@ -1861,9 +2125,9 @@ int camera_set_state_changed_cb(camera_h camera, camera_state_changed_cb callbac
* @param[in] camera The handle to the camera
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_set_state_changed_cb()
*/
@@ -1877,9 +2141,9 @@ int camera_unset_state_changed_cb(camera_h camera);
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_unset_interrupted_cb()
* @see camera_interrupted_cb()
@@ -1892,9 +2156,9 @@ int camera_set_interrupted_cb(camera_h camera, camera_interrupted_cb callback, v
* @param[in] camera The handle to the camera
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_set_interrupted_cb()
*/
@@ -1933,9 +2197,9 @@ int camera_unset_interrupt_started_cb(camera_h camera);
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function will invoke camera_focus_changed_cb() when the auto-focus state changes.
* @see camera_start_focusing()
@@ -1951,9 +2215,9 @@ int camera_set_focus_changed_cb(camera_h camera, camera_focus_changed_cb callbac
* @param[in] camera The handle to the camera
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_set_focus_changed_cb()
*/
@@ -1973,9 +2237,9 @@ int camera_unset_focus_changed_cb(camera_h camera);
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function will invoke camera_error_cb() when an asynchronous operation error occurs.
@@ -1990,9 +2254,9 @@ int camera_set_error_cb(camera_h camera, camera_error_cb callback, void *user_da
* @param[in] camera The handle to the camera
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_set_error_cb()
*/
@@ -2005,9 +2269,9 @@ int camera_unset_error_cb(camera_h camera);
* @param[out] state The current state of the device
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
*/
int camera_get_device_state(camera_device_e device, camera_device_state_e *state);
@@ -2019,10 +2283,10 @@ int camera_get_device_state(camera_device_e device, camera_device_state_e *state
* @param[out] cb_id The id of registered callback
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
* @retval #CAMERA_ERROR_OUT_OF_MEMORY Out of memory
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @post This function will invoke camera_device_state_changed_cb() when the camera device's state changes.
* @see camera_remove_device_state_changed_cb()
* @see camera_device_state_changed_cb()
@@ -2035,9 +2299,9 @@ int camera_add_device_state_changed_cb(camera_device_state_changed_cb callback,
* @param[in] cb_id The id of registered callback
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @see camera_add_device_state_changed_cb()
*/
int camera_remove_device_state_changed_cb(int cb_id);
@@ -2204,10 +2468,10 @@ typedef bool (*camera_attr_supported_ptz_type_cb)(camera_attr_ptz_type_e type, v
* @param[in] fps The frame rate
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED.
* @see camera_start_preview()
@@ -2223,9 +2487,9 @@ int camera_attr_set_preview_fps(camera_h camera, camera_attr_fps_e fps);
* @param[out] fps The frames per second of the preview video stream
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_preview_fps()
* @see camera_attr_foreach_supported_fps()
@@ -2233,6 +2497,87 @@ int camera_attr_set_preview_fps(camera_h camera, camera_attr_fps_e fps);
int camera_attr_get_preview_fps(camera_h camera, camera_attr_fps_e *fps);
/**
+ * @brief Sets the bitrate of extra preview.
+ * @since_tizen 7.0
+ * @param[in] camera The handle to the camera
+ * @param[in] stream_id The id of extra preview stream
+ * @param[in] bitrate The bitrate(bps) of extra preview
+ * @return @c 0 on success, otherwise a negative error value
+ * @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
+ * @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
+ * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
+ * @see camera_attr_get_extra_preview_bitrate()
+ */
+int camera_attr_set_extra_preview_bitrate(camera_h camera, int stream_id, int bitrate);
+
+/**
+ * @brief Gets the bitrate of extra preview.
+ * @since_tizen 7.0
+ * @param[in] camera The handle to the camera
+ * @param[in] stream_id The id of extra preview stream
+ * @param[out] bitrate The bitrate(bps) of extra preview stream
+ * @return @c 0 on success, otherwise a negative error value
+ * @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
+ * @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
+ * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
+ * @see camera_attr_set_extra_preview_bitrate()
+ */
+int camera_attr_get_extra_preview_bitrate(camera_h camera, int stream_id, int *bitrate);
+
+/**
+ * @brief Sets the GOP (Group Of Pictures) interval of extra preview.
+ * @since_tizen 7.0
+ * @remarks The recommended range is from 1,000 (1 second) to 600,000 (10 minutes). \n
+ * But, due to codec limitations, it may not apply.
+ * @param[in] camera The handle to the camera
+ * @param[in] stream_id The id of extra preview stream
+ * @param[in] interval The GOP interval of extra preview (millisecond)
+ * @return @c 0 on success, otherwise a negative error value
+ * @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
+ * @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
+ * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
+ * @see camera_attr_get_extra_preview_gop_interval()
+ */
+int camera_attr_set_extra_preview_gop_interval(camera_h camera, int stream_id, int interval);
+
+/**
+ * @brief Gets the GOP (Group Of Pictures) interval of extra preview.
+ * @since_tizen 7.0
+ * @param[in] camera The handle to the camera
+ * @param[in] stream_id The id of extra preview stream
+ * @param[out] interval The GOP interval of extra preview (millisecond)
+ * @return @c 0 on success, otherwise a negative error value
+ * @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
+ * @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
+ * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
+ * @see camera_attr_set_extra_preview_gop_interval()
+ */
+int camera_attr_get_extra_preview_gop_interval(camera_h camera, int stream_id, int *interval);
+
+/**
+ * @brief Gets the rotation of preview frame.
+ * @since_tizen 7.0
+ * @remarks The function should be called in camera_preview_cb(),\n
+ * otherwise, it will return #CAMERA_ERROR_INVALID_OPERATION.
+ * @param[in] camera The handle to the camera
+ * @param[out] rotation The rotation of preview frame
+ * @return @c 0 on success, otherwise a negative error value
+ * @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
+ * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
+ */
+int camera_attr_get_preview_frame_rotation(camera_h camera, camera_rotation_e *rotation);
+
+/**
* @}
*/
@@ -2249,9 +2594,9 @@ int camera_attr_get_preview_fps(camera_h camera, camera_attr_fps_e *fps);
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function invokes camera_attr_supported_fps_cb() repeatedly to get each supported FPS mode.
* @see camera_attr_set_preview_fps()
@@ -2270,9 +2615,9 @@ int camera_attr_foreach_supported_fps(camera_h camera, camera_attr_supported_fps
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function invokes camera_attr_supported_fps_cb() repeatedly to get each supported FPS mode.
* @see camera_attr_set_preview_fps()
@@ -2298,10 +2643,10 @@ int camera_attr_foreach_supported_fps_by_resolution(camera_h camera, int width,
* @param[in] quality The quality of image (1 ~ 100)
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
* @see camera_start_preview()
@@ -2316,9 +2661,9 @@ int camera_attr_set_image_quality(camera_h camera, int quality);
* @param[out] quality The quality of the image(1 ~ 100)
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_image_quality()
*/
@@ -2331,9 +2676,9 @@ int camera_attr_get_image_quality(camera_h camera, int *quality);
* @param[out] bitrate The bit rate of encoded preview
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_encoded_preview_bitrate()
*/
@@ -2348,9 +2693,9 @@ int camera_attr_get_encoded_preview_bitrate(camera_h camera, int *bitrate);
* @param[in] bitrate The bit rate of encoded preview
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_get_encoded_preview_bitrate()
*/
@@ -2363,9 +2708,9 @@ int camera_attr_set_encoded_preview_bitrate(camera_h camera, int bitrate);
* @param[out] interval The GOP interval of encoded preview (millisecond)
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_encoded_preview_gop_interval()
*/
@@ -2380,9 +2725,9 @@ int camera_attr_get_encoded_preview_gop_interval(camera_h camera, int *interval)
* @param[in] interval The GOP interval of encoded preview (millisecond)
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_get_encoded_preview_gop_interval()
*/
@@ -2396,10 +2741,10 @@ int camera_attr_set_encoded_preview_gop_interval(camera_h camera, int interval);
* @param[in] zoom The zoom level
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
* @see camera_attr_get_zoom()
@@ -2414,9 +2759,9 @@ int camera_attr_set_zoom(camera_h camera, int zoom);
* @param[out] zoom The zoom level
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_zoom()
* @see camera_attr_get_zoom_range()
@@ -2432,9 +2777,9 @@ int camera_attr_get_zoom(camera_h camera, int *zoom);
* @param[out] max The maximum zoom level
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_zoom()
* @see camera_attr_get_zoom()
@@ -2449,10 +2794,10 @@ int camera_attr_get_zoom_range(camera_h camera, int *min, int *max);
* @param[in] mode The auto focus mode
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
* @see camera_attr_get_af_mode()
@@ -2468,9 +2813,9 @@ int camera_attr_set_af_mode(camera_h camera, camera_attr_af_mode_e mode);
* @param[out] mode The auto focus mode
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_foreach_supported_af_mode()
* @see camera_attr_set_af_mode()
@@ -2488,11 +2833,11 @@ int camera_attr_get_af_mode(camera_h camera, camera_attr_af_mode_e *mode);
* @param[in] y The y coordinates of the focus area
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
* @see camera_attr_set_af_mode()
@@ -2507,10 +2852,10 @@ int camera_attr_set_af_area(camera_h camera, int x, int y);
* @param[in] camera The handle to the camera
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_af_mode()
* @see camera_attr_set_af_area()
@@ -2534,9 +2879,9 @@ int camera_attr_clear_af_area(camera_h camera);
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function invokes camera_attr_supported_af_mode_cb() to get all the supported auto focus modes.
* @see camera_attr_set_af_mode()
@@ -2561,10 +2906,10 @@ int camera_attr_foreach_supported_af_mode(camera_h camera, camera_attr_supported
* @param[in] mode The exposure mode
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
* @see camera_attr_get_exposure_mode()
@@ -2579,9 +2924,9 @@ int camera_attr_set_exposure_mode(camera_h camera, camera_attr_exposure_mode_e m
* @param[out] mode The exposure mode
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_exposure_mode()
* @see camera_attr_foreach_supported_exposure_mode()
@@ -2605,9 +2950,9 @@ int camera_attr_get_exposure_mode(camera_h camera, camera_attr_exposure_mode_e *
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function invokes camera_attr_supported_exposure_mode_cb() to get all the supported exposure modes.
* @see camera_attr_set_exposure_mode()
@@ -2632,9 +2977,9 @@ int camera_attr_foreach_supported_exposure_mode(camera_h camera, camera_attr_sup
* @param[in] value The exposure value
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_get_exposure()
*/
@@ -2647,9 +2992,9 @@ int camera_attr_set_exposure(camera_h camera, int value);
* @param[out] value The exposure value
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_exposure()
*/
@@ -2664,9 +3009,9 @@ int camera_attr_get_exposure(camera_h camera, int *value);
* @param[out] max The maximum exposure value
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_exposure()
*/
@@ -2679,10 +3024,10 @@ int camera_attr_get_exposure_range(camera_h camera, int *min, int *max);
* @param[in] iso The ISO level
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
* @see camera_attr_get_iso()
@@ -2697,9 +3042,9 @@ int camera_attr_set_iso(camera_h camera, camera_attr_iso_e iso);
* @param[out] iso The ISO level
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_iso()
* @see camera_attr_foreach_supported_iso()
@@ -2723,9 +3068,9 @@ int camera_attr_get_iso(camera_h camera, camera_attr_iso_e *iso);
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function invokes camera_attr_supported_iso_cb() to get all the supported ISO levels.
* @see camera_attr_set_iso()
@@ -2751,9 +3096,9 @@ int camera_attr_foreach_supported_iso(camera_h camera, camera_attr_supported_iso
* @param[in] mode The theater mode
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre This function is valid only when the external display is connected.
* @see camera_attr_get_theater_mode()
@@ -2767,9 +3112,9 @@ int camera_attr_set_theater_mode(camera_h camera, camera_attr_theater_mode_e mod
* @param[out] mode The theater mode
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_theater_mode()
*/
@@ -2792,9 +3137,9 @@ int camera_attr_get_theater_mode(camera_h camera, camera_attr_theater_mode_e *mo
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function invokes camera_attr_supported_theater_mode_cb() to get all supported theater modes.
* @see camera_attr_set_theater_mode()
@@ -2822,10 +3167,10 @@ int camera_attr_foreach_supported_theater_mode(camera_h camera, camera_attr_supp
* @param[in] level The brightness level
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
* @see camera_attr_get_brightness()
@@ -2840,9 +3185,9 @@ int camera_attr_set_brightness(camera_h camera, int level);
* @param[out] level The brightness level
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_brightness()
* @see camera_attr_get_brightness_range()
@@ -2858,9 +3203,9 @@ int camera_attr_get_brightness(camera_h camera, int *level);
* @param[out] max The maximum brightness level
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_brightness()
* @see camera_attr_get_brightness()
@@ -2874,10 +3219,10 @@ int camera_attr_get_brightness_range(camera_h camera, int *min, int *max);
* @param[in] level The contrast level
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
* @see camera_attr_get_contrast()
@@ -2892,9 +3237,9 @@ int camera_attr_set_contrast(camera_h camera, int level);
* @param[out] level The contrast level
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_contrast()
* @see camera_attr_get_contrast_range()
@@ -2910,9 +3255,9 @@ int camera_attr_get_contrast(camera_h camera, int *level);
* @param[out] max The maximum contrast level
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_contrast()
* @see camera_attr_get_contrast()
@@ -2926,8 +3271,8 @@ int camera_attr_get_contrast_range(camera_h camera, int *min, int *max);
* @param[in] level The hue level
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
- * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
+ * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @see camera_attr_get_hue()
* @see camera_attr_get_hue_range()
*/
@@ -2940,8 +3285,8 @@ int camera_attr_set_hue(camera_h camera, int level);
* @param[out] level The hue level
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
- * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
+ * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @see camera_attr_set_hue()
* @see camera_attr_get_hue_range()
*/
@@ -2956,8 +3301,8 @@ int camera_attr_get_hue(camera_h camera, int *level);
* @param[out] max The maximum hue level
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
- * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
+ * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @see camera_attr_set_hue()
* @see camera_attr_get_hue()
*/
@@ -2970,10 +3315,10 @@ int camera_attr_get_hue_range(camera_h camera, int *min, int *max);
* @param[in] whitebalance The white balance mode
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
* @see camera_attr_foreach_supported_whitebalance()
@@ -2988,9 +3333,9 @@ int camera_attr_set_whitebalance(camera_h camera, camera_attr_whitebalance_e whi
* @param[out] whitebalance The white balance mode
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_foreach_supported_whitebalance()
* @see camera_attr_set_whitebalance()
@@ -3014,9 +3359,9 @@ int camera_attr_get_whitebalance(camera_h camera, camera_attr_whitebalance_e *wh
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function invokes camera_attr_supported_whitebalance_cb() to get all the supported white balances.
* @see camera_attr_set_whitebalance()
@@ -3041,10 +3386,10 @@ int camera_attr_foreach_supported_whitebalance(camera_h camera, camera_attr_supp
* @param[in] effect The camera effect mode
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
* @see camera_attr_foreach_supported_effect()
@@ -3060,9 +3405,9 @@ int camera_attr_set_effect(camera_h camera, camera_attr_effect_mode_e effect);
* @param[out] effect The camera effect mode
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_foreach_supported_effect()
* @see camera_attr_set_effect()
@@ -3086,9 +3431,9 @@ int camera_attr_get_effect(camera_h camera, camera_attr_effect_mode_e *effect);
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function invokes camera_attr_supported_effect_cb() to get all the supported effect modes.
* @see camera_attr_set_effect()
@@ -3113,10 +3458,10 @@ int camera_attr_foreach_supported_effect(camera_h camera, camera_attr_supported_
* @param[in] mode The scene mode
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
* @see camera_attr_foreach_supported_scene_mode()
@@ -3131,9 +3476,9 @@ int camera_attr_set_scene_mode(camera_h camera, camera_attr_scene_mode_e mode);
* @param[out] mode The scene mode
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_foreach_supported_scene_mode()
* @see camera_attr_set_scene_mode()
@@ -3157,9 +3502,9 @@ int camera_attr_get_scene_mode(camera_h camera, camera_attr_scene_mode_e *mode);
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function invokes camera_attr_supported_scene_mode_cb() to get all the supported scene modes.
* @see camera_attr_set_scene_mode()
@@ -3184,9 +3529,9 @@ int camera_attr_foreach_supported_scene_mode(camera_h camera, camera_attr_suppor
* @param[in] enable If @c true writing EXIF tags in a JPEG file is enabled, otherwise @c false
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_is_enabled_tag()
*/
@@ -3199,9 +3544,9 @@ int camera_attr_enable_tag(camera_h camera, bool enable);
* @param[out] enabled If @c true camera information is enabled, otherwise @c false
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_enable_tag()
*/
@@ -3214,9 +3559,9 @@ int camera_attr_is_enabled_tag(camera_h camera, bool *enabled);
* @param[in] description The string with description
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_get_tag_image_description()
*/
@@ -3230,9 +3575,9 @@ int camera_attr_set_tag_image_description(camera_h camera, const char *descripti
* @param[out] description A pointer to a string
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_tag_image_description()
*/
@@ -3245,9 +3590,9 @@ int camera_attr_get_tag_image_description(camera_h camera, char **description);
* @param[in] orientation The camera orientation
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_get_tag_orientation()
*/
@@ -3260,9 +3605,9 @@ int camera_attr_set_tag_orientation(camera_h camera, camera_attr_tag_orientation
* @param[out] orientation The camera orientation
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_tag_orientation()
*/
@@ -3275,9 +3620,9 @@ int camera_attr_get_tag_orientation(camera_h camera, camera_attr_tag_orientation
* @param[in] software The software information tag
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_get_tag_software()
*/
@@ -3291,9 +3636,9 @@ int camera_attr_set_tag_software(camera_h camera, const char *software);
* @param[out] software A pointer to a string
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_tag_software()
*/
@@ -3308,10 +3653,10 @@ int camera_attr_get_tag_software(camera_h camera, char **software);
* @param[in] altitude The altitude data
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
* @see camera_attr_get_geotag()
@@ -3328,9 +3673,9 @@ int camera_attr_set_geotag(camera_h camera, double latitude, double longitude, d
* @param[out] altitude The altitude data
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_geotag()
* @see camera_attr_remove_geotag()
@@ -3343,10 +3688,10 @@ int camera_attr_get_geotag(camera_h camera, double *latitude, double *longitude,
* @param[in] camera The handle to the camera
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
* @see camera_attr_set_geotag()
@@ -3363,10 +3708,10 @@ int camera_attr_remove_geotag(camera_h camera);
* @param[in] mode The flash mode
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @retval #CAMERA_ERROR_DEVICE_BUSY The flash was preempted by other API
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
@@ -3382,9 +3727,9 @@ int camera_attr_set_flash_mode(camera_h camera, camera_attr_flash_mode_e mode);
* @param[out] mode The flash mode
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_foreach_supported_flash_mode()
* @see camera_attr_set_flash_mode()
@@ -3408,9 +3753,9 @@ int camera_attr_get_flash_mode(camera_h camera, camera_attr_flash_mode_e *mode);
* @param[in] user_data The user data passed to the callback registration function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function invokes camera_attr_supported_flash_mode_cb() to get all supported flash modes.
* @see camera_attr_set_flash_mode()
@@ -3435,9 +3780,9 @@ int camera_attr_foreach_supported_flash_mode(camera_h camera, camera_attr_suppor
* @param[out] angle The orientation angle
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_set_display_rotation()
*/
@@ -3450,9 +3795,9 @@ int camera_attr_get_lens_orientation(camera_h camera, int *angle);
* @param[in] rotation The stream rotation
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED.
* @see camera_attr_get_stream_rotation()
@@ -3466,9 +3811,9 @@ int camera_attr_set_stream_rotation(camera_h camera, camera_rotation_e rotation)
* @param[out] rotation The stream rotation
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED.
* @see camera_attr_set_stream_rotation()
@@ -3492,9 +3837,9 @@ int camera_attr_get_stream_rotation(camera_h camera, camera_rotation_e *rotation
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function invokes camera_attr_supported_stream_rotation_cb() to get all supported stream rotation mode.
* @see camera_attr_set_stream_rotation()
@@ -3519,10 +3864,10 @@ int camera_attr_foreach_supported_stream_rotation(camera_h camera, camera_attr_s
* @param[in] flip The stream flip
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED.
* @see camera_attr_set_stream_rotation()
@@ -3536,9 +3881,9 @@ int camera_attr_set_stream_flip(camera_h camera, camera_flip_e flip);
* @param[out] flip The stream flip
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED.
* @see camera_attr_set_stream_rotation()
@@ -3562,9 +3907,9 @@ int camera_attr_get_stream_flip(camera_h camera, camera_flip_e *flip);
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function invokes camera_attr_supported_stream_flip_cb() to get all supported stream flip mode.
* @see camera_attr_set_stream_flip()
@@ -3605,10 +3950,10 @@ typedef void (*camera_attr_hdr_progress_cb)(int percent, void *user_data);
* @param[in] mode The mode of HDR capture
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
* @see camera_attr_get_hdr_mode()
@@ -3626,9 +3971,9 @@ int camera_attr_set_hdr_mode(camera_h camera, camera_attr_hdr_mode_e mode);
* @param[out] mode The mode of HDR capture
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_hdr_mode()
* @see camera_attr_set_hdr_capture_progress_cb()
@@ -3646,9 +3991,9 @@ int camera_attr_get_hdr_mode(camera_h camera, camera_attr_hdr_mode_e *mode);
* @param[in] user_data The user data passed to the callback registration function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_hdr_mode()
* @see camera_attr_get_hdr_mode()
@@ -3663,9 +4008,9 @@ int camera_attr_set_hdr_capture_progress_cb(camera_h camera, camera_attr_hdr_pro
* @param[in] camera The handle to the camera
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_hdr_mode()
* @see camera_attr_get_hdr_mode()
@@ -3682,9 +4027,9 @@ int camera_attr_unset_hdr_capture_progress_cb(camera_h camera);
* @param[in] camera The handle to the camera
* @return @c true if supported, otherwise @c false
* @exception #CAMERA_ERROR_NONE Successful
+ * @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @exception #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @exception #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @see camera_attr_set_hdr_mode()
* @see camera_attr_get_hdr_mode()
* @see camera_attr_set_hdr_capture_progress_cb()
@@ -3700,9 +4045,9 @@ bool camera_attr_is_supported_hdr_capture(camera_h camera);
* @param[in] enable If @c true the anti-shake feature is enabled, otherwise @c false
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_is_enabled_anti_shake()
* @see camera_attr_is_supported_anti_shake()
@@ -3717,9 +4062,9 @@ int camera_attr_enable_anti_shake(camera_h camera, bool enable);
* @param[out] enabled The state of anti-shake
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_enable_anti_shake()
* @see camera_attr_is_supported_anti_shake()
@@ -3734,9 +4079,9 @@ int camera_attr_is_enabled_anti_shake(camera_h camera, bool *enabled);
* @param[in] camera The handle to the camera
* @return @c true if supported, otherwise @c false
* @exception #CAMERA_ERROR_NONE Successful
+ * @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @exception #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @exception #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @see camera_attr_enable_anti_shake()
* @see camera_attr_is_enabled_anti_shake()
*/
@@ -3751,9 +4096,9 @@ bool camera_attr_is_supported_anti_shake(camera_h camera);
* @param[in] enable If @c true video stabilization is enabled, otherwise @c false
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_is_enabled_video_stabilization()
* @see camera_attr_is_supported_video_stabilization()
@@ -3768,9 +4113,9 @@ int camera_attr_enable_video_stabilization(camera_h camera, bool enable);
* @param[out] enabled The state of video stabilization
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_enable_video_stabilization()
* @see camera_attr_is_supported_video_stabilization()
@@ -3785,9 +4130,9 @@ int camera_attr_is_enabled_video_stabilization(camera_h camera, bool *enabled);
* @param[in] camera The handle to the camera
* @return @c true if supported, otherwise @c false
* @exception #CAMERA_ERROR_NONE Successful
+ * @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @exception #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @exception #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @see camera_attr_enable_video_stabilization()
* @see camera_attr_is_enabled_video_stabilization()
*/
@@ -3800,10 +4145,10 @@ bool camera_attr_is_supported_video_stabilization(camera_h camera);
* @param[in] enable If @c true auto contrast is enabled, otherwise @c false
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
* @see camera_attr_is_enabled_auto_contrast()
@@ -3817,9 +4162,9 @@ int camera_attr_enable_auto_contrast(camera_h camera, bool enable);
* @param[out] enabled The state of auto contrast
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_enable_auto_contrast()
*/
@@ -3842,9 +4187,9 @@ int camera_attr_is_enabled_auto_contrast(camera_h camera, bool *enabled);
* @param[in] camera The handle to the camera
* @return true on supported, otherwise false
* @exception #CAMERA_ERROR_NONE Successful
+ * @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @exception #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @exception #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @exception #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @see camera_attr_enable_auto_contrast()
* @see camera_attr_is_enabled_auto_contrast()
*/
@@ -3867,10 +4212,10 @@ bool camera_attr_is_supported_auto_contrast(camera_h camera);
* @param[in] disable If @c true shutter sound is disabled, otherwise @c false
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_OPERATION Disabling shutter sound is not permitted
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
*/
int camera_attr_disable_shutter_sound(camera_h camera, bool disable);
@@ -3883,10 +4228,10 @@ int camera_attr_disable_shutter_sound(camera_h camera, bool disable);
* @param[in] pan_step The step to move the camera
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_PREVIEW.
* @see camera_attr_get_pan()
@@ -3901,9 +4246,9 @@ int camera_attr_set_pan(camera_h camera, camera_attr_ptz_move_type_e move_type,
* @param[out] pan_step The current horizontal distance from the starting point.
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_pan()
* @see camera_attr_get_pan_range()
@@ -3919,9 +4264,9 @@ int camera_attr_get_pan(camera_h camera, int *pan_step);
* @param[out] max The upper limit for pan
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_pan()
* @see camera_attr_get_pan()
@@ -3936,10 +4281,10 @@ int camera_attr_get_pan_range(camera_h camera, int *min, int *max);
* @param[in] tilt_step The step to move the camera
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_PREVIEW.
* @see camera_attr_get_tilt()
@@ -3954,9 +4299,9 @@ int camera_attr_set_tilt(camera_h camera, camera_attr_ptz_move_type_e move_type,
* @param[out] tilt_step The current vertical distance from the starting point.
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_tilt()
* @see camera_attr_get_tilt_range()
@@ -3972,9 +4317,9 @@ int camera_attr_get_tilt(camera_h camera, int *tilt_step);
* @param[out] max The upper limit for tilt
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_tilt()
* @see camera_attr_get_tilt()
@@ -3988,10 +4333,10 @@ int camera_attr_get_tilt_range(camera_h camera, int *min, int *max);
* @param[in] ptz_type PTZ type
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_INVALID_STATE Invalid state
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @pre The camera state must be set to #CAMERA_STATE_PREVIEW.
* @see camera_attr_get_pan()
@@ -4021,9 +4366,9 @@ int camera_attr_set_ptz_type(camera_h camera, camera_attr_ptz_type_e ptz_type);
* @param[in] user_data The user data to be passed to the callback function
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
* @retval #CAMERA_ERROR_PERMISSION_DENIED The access to the resources can not be granted
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @post This function invokes camera_attr_supported_ptz_type_cb() to get all supported ptz type.
* @see camera_attr_set_ptz_type()
@@ -4053,9 +4398,9 @@ int camera_attr_foreach_supported_ptz_type(camera_h camera, camera_attr_supporte
* @param[in] height Height of area
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_get_display_roi_area()
*/
@@ -4071,9 +4416,9 @@ int camera_attr_set_display_roi_area(camera_h camera, int x, int y, int width, i
* @param[out] height Height of area
* @return @c 0 on success, otherwise a negative error value
* @retval #CAMERA_ERROR_NONE Successful
+ * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
* @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
* @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
* @see camera_attr_set_display_roi_area()
*/
diff --git a/include/camera_internal.h b/include/camera_internal.h
index c0bf836..fb99ffb 100644
--- a/include/camera_internal.h
+++ b/include/camera_internal.h
@@ -42,12 +42,6 @@ extern "C" {
#define DEVICE_ID_MAX_LENGTH 64
-typedef enum {
- CAMERA_DEVICE_TYPE_BUILTIN = 0, /**< Built-in camera */
- CAMERA_DEVICE_TYPE_USB, /**< USB connected camera */
- CAMERA_DEVICE_TYPE_NETWORK /**< Network camera */
-} camera_device_type_e;
-
typedef struct _camera_device_s {
camera_device_type_e type;
camera_device_e index;
@@ -61,33 +55,6 @@ typedef struct _camera_device_list_s {
camera_device_s device[CAMERA_DEVICE_MAX];
} camera_device_list_s;
-typedef struct camera_device_manager *camera_device_manager_h;
-
-/**
- * @internal
- * @brief Called when the connection state of a camera device was changed.
- * @since_tizen 6.5
- * @param[in] device The camera device
- * @param[in] is_connected The state of device connection: (@c true = connected, @c false = disconnected)
- * @param[in] user_data The user data passed from the callback registration function
- * @see camera_device_manager_add_device_connection_changed_cb()
- * @see camera_device_manager_remove_device_connection_changed_cb()
- */
-typedef void (*camera_device_connection_changed_cb)(camera_device_s *device, bool is_connected, void *user_data);
-
-/**
- * @internal
- * @brief Called to register for notifications about delivering a copy of the new extra preview frames.
- * @since_tizen 6.5
- * @param[in] frame The reference pointer to extra preview stream data
- * @param[in] stream_id The id of stream
- * @param[in] user_data The user data passed from the callback registration function
- * @pre camera_start_preview() will invoke this callback function if you register this callback using camera_set_extra_preview_cb().
- * @see camera_start_preview()
- * @see camera_set_extra_preview_cb()
- * @see camera_unset_extra_preview_cb()
- */
-typedef void (*camera_extra_preview_cb)(camera_preview_data_s *frame, int stream_id, void *user_data);
/**
* @internal
@@ -158,105 +125,6 @@ void camera_create_preview_frame(MMCamcorderVideoStreamDataType *stream, int num
/**
* @internal
- * @brief Creates a new camera handle for controlling a network camera.
- * @since_tizen 6.0
- * @remarks A @a camera must be released using camera_destroy().
- * @param[in] device The network camera to access
- * @param[out] camera A newly returned handle to the camera
- * @return @c 0 on success, otherwise a negative error value
- * @retval #CAMERA_ERROR_NONE Successful
- * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_OUT_OF_MEMORY Out of memory
- * @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
- * @post If it succeeds, the camera state will be #CAMERA_STATE_CREATED.
- *
- * @see camera_destroy()
- */
-int camera_create_network(camera_device_e device, camera_h *camera);
-
-/**
- * @internal
- * @brief Initialize a camera device manager.
- * @since_tizen 6.0
- * @remarks If you call camera_device_manager_initialize() multiple times,
- * you have to call camera_device_manager_deinitialize() the same number of times.
- * @param[out] manager A newly returned handle to the camera device manager
- * @return @c 0 on success, otherwise a negative error value
- * @retval #CAMERA_ERROR_NONE Successful
- * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_OUT_OF_MEMORY Out of memory
- * @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
- * @see camera_device_manager_deinitialize()
- */
-int camera_device_manager_initialize(camera_device_manager_h *manager);
-
-/**
- * @internal
- * @brief Deinitialize the camera device manager handle.
- * @since_tizen 6.0
- * @remarks If you call camera_device_manager_deinitialize() multiple times,
- * you have to call camera_device_manager_initialize() the same number of times.
- * @param[in] manager The handle to the camera device manager
- * @return @c 0 on success, otherwise a negative error value
- * @retval #CAMERA_ERROR_NONE Successful
- * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
- * @see camera_device_manager_initialize()
- */
-int camera_device_manager_deinitialize(camera_device_manager_h manager);
-
-/**
- * @internal
- * @brief Gets a list of available camera devices.
- * @since_tizen 6.0
- * @param[in] manager The handle to the camera device manager
- * @param[out] list A list of available camera devices
- * @return @c 0 on success, otherwise a negative error value
- * @retval #CAMERA_ERROR_NONE Successful
- * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_OUT_OF_MEMORY Out of memory
- * @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
- */
-int camera_device_manager_get_device_list(camera_device_manager_h manager, camera_device_list_s *list);
-
-/**
- * @internal
- * @brief Registers a callback function to be called when the connection state of camera device is changed.
- * @since_tizen 6.5
- * @param[in] manager The handle to the camera device manager
- * @param[in] callback The callback function to register
- * @param[in] user_data The user data to be passed to the callback function
- * @param[out] cb_id The id of registered callback
- * @return @c 0 on success, otherwise a negative error value
- * @retval #CAMERA_ERROR_NONE Successful
- * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
- * @retval #CAMERA_ERROR_OUT_OF_MEMORY Out of memory
- * @post camera_device_connection_changed_cb() will be invoked when the connection state of camera device is changed.
- * @see camera_device_manager_remove_device_connection_changed_cb()
- * @see camera_device_connection_changed_cb()
- */
-int camera_device_manager_add_device_connection_changed_cb(camera_device_manager_h manager, camera_device_connection_changed_cb callback, void *user_data, int *cb_id);
-
-/**
- * @internal
- * @brief Unregisters the callback function.
- * @since_tizen 6.5
- * @param[in] manager The handle to the camera device manager
- * @param[in] cb_id The id of registered callback
- * @return @c 0 on success, otherwise a negative error value
- * @retval #CAMERA_ERROR_NONE Successful
- * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_INVALID_OPERATION Invalid operation
- * @see camera_device_manager_add_device_changed_cb()
- */
-int camera_device_manager_remove_device_connection_changed_cb(camera_device_manager_h manager, int cb_id);
-
-/**
- * @internal
* @brief Sets the brightness level of flash.
* @since_tizen 6.5
* @remarks If the min value is greater than the max value from camera_attr_get_flash_brightness_range(), \n
@@ -311,83 +179,6 @@ int camera_attr_get_flash_brightness_range(camera_h camera, int *min, int *max);
/**
* @internal
- * @brief Registers a callback function to be called for extra preview frames.
- * @since_tizen 6.5
- * @param[in] camera The handle to the camera
- * @param[in] callback The callback function to be registered
- * @param[in] user_data The user data to be passed to the callback function
- * @return @c 0 on success, otherwise a negative error value
- * @retval #CAMERA_ERROR_NONE Successful
- * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
- * @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
- * @see camera_start_preview()
- * @see camera_unset_extra_preview_cb()
- * @see camera_extra_preview_cb()
- */
-int camera_set_extra_preview_cb(camera_h camera, camera_extra_preview_cb callback, void *user_data);
-
-/**
- * @internal
- * @brief Unregisters the callback function.
- * @since_tizen 6.5
- * @param[in] camera The handle to the camera
- * @return @c 0 on success, otherwise a negative error value
- * @retval #CAMERA_ERROR_NONE Successful
- * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
- * @see camera_set_extra_preview_cb()
- */
-int camera_unset_extra_preview_cb(camera_h camera);
-
-/**
- * @internal
- * @brief Sets the extra preview stream format.
- * @since_tizen 6.5
- * @param[in] camera The handle to the camera
- * @param[in] stream_id The id of extra preview stream
- * @param[in] pixel_format The pixel format of extra preview stream
- * @param[in] width The width of extra preview stream
- * @param[in] height The height of extra preview stream
- * @param[in] fps The fps of extra preview stream
- * @return @c 0 on success, otherwise a negative error value
- * @retval #CAMERA_ERROR_NONE Successful
- * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_INVALID_STATE Invalid state
- * @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
- * @pre The camera state must be set to #CAMERA_STATE_CREATED or #CAMERA_STATE_PREVIEW.
- * @see camera_start_preview()
- * @see camera_set_extra_preview_cb()
- * @see camera_unset_extra_preview_cb()
- * @see camera_get_extra_preview_stream_format()
- */
-int camera_set_extra_preview_stream_format(camera_h camera, int stream_id, camera_pixel_format_e pixel_format, int width, int height, int fps);
-
-/**
- * @internal
- * @brief Gets the extra preview stream format.
- * @since_tizen 6.5
- * @param[in] camera The handle to the camera
- * @param[in] stream_id The id of extra preview stream
- * @param[out] pixel_format The pixel format of extra preview stream
- * @param[out] width The width of extra preview stream
- * @param[out] height The height of extra preview stream
- * @param[out] fps The fps of extra preview stream
- * @return @c 0 on success, otherwise a negative error value
- * @retval #CAMERA_ERROR_NONE Successful
- * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_INVALID_STATE Invalid state
- * @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
- * @pre The camera state must be set to #CAMERA_STATE_PREVIEW.
- * @see camera_start_preview()
- * @see camera_set_extra_preview_cb()
- * @see camera_unset_extra_preview_cb()
- * @see camera_set_extra_preview_stream_format()
- */
-int camera_get_extra_preview_stream_format(camera_h camera, int stream_id, camera_pixel_format_e *pixel_format, int *width, int *height, int *fps);
-
-/**
- * @internal
* @brief Sets the manual focus level.
* @since_tizen 6.5
* @remarks The auto focusing will be stopped when camera_attr_set_focus_level() is called.
@@ -438,92 +229,6 @@ int camera_attr_get_focus_level(camera_h camera, int *level);
int camera_attr_get_focus_level_range(camera_h camera, int *min, int *max);
/**
- * @internal
- * @brief Sets the bitrate of extra preview.
- * @since_tizen 6.5
- * @param[in] camera The handle to the camera
- * @param[in] stream_id The id of extra preview stream
- * @param[in] bitrate The bitrate(bps) of extra preview
- * @return @c 0 on success, otherwise a negative error value
- * @retval #CAMERA_ERROR_NONE Successful
- * @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
- * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
- * @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
- * @see camera_attr_get_extra_preview_bitrate()
- */
-int camera_attr_set_extra_preview_bitrate(camera_h camera, int stream_id, int bitrate);
-
-/**
- * @internal
- * @brief Gets the bitrate of extra preview.
- * @since_tizen 6.5
- * @param[in] camera The handle to the camera
- * @param[in] stream_id The id of extra preview stream
- * @param[out] bitrate The bitrate(bps) of extra preview stream
- * @return @c 0 on success, otherwise a negative error value
- * @retval #CAMERA_ERROR_NONE Successful
- * @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
- * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
- * @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
- * @see camera_attr_set_extra_preview_bitrate()
- */
-int camera_attr_get_extra_preview_bitrate(camera_h camera, int stream_id, int *bitrate);
-
-/**
- * @internal
- * @brief Sets the GOP (Group Of Pictures) interval of extra preview.
- * @since_tizen 6.5
- * @remarks The recommended range is from 1,000 (1 second) to 600,000 (10 minutes). \n
- * But, due to codec limitations, it may not apply.
- * @param[in] camera The handle to the camera
- * @param[in] stream_id The id of extra preview stream
- * @param[in] interval The GOP interval of extra preview (millisecond)
- * @return @c 0 on success, otherwise a negative error value
- * @retval #CAMERA_ERROR_NONE Successful
- * @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
- * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
- * @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
- * @see camera_attr_get_extra_preview_gop_interval()
- */
-int camera_attr_set_extra_preview_gop_interval(camera_h camera, int stream_id, int interval);
-
-/**
- * @internal
- * @brief Gets the GOP (Group Of Pictures) interval of extra preview.
- * @since_tizen 6.5
- * @param[in] camera The handle to the camera
- * @param[in] stream_id The id of extra preview stream
- * @param[out] interval The GOP interval of extra preview (millisecond)
- * @return @c 0 on success, otherwise a negative error value
- * @retval #CAMERA_ERROR_NONE Successful
- * @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
- * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_NOT_SUPPORTED The feature is not supported
- * @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
- * @see camera_attr_set_extra_preview_gop_interval()
- */
-int camera_attr_get_extra_preview_gop_interval(camera_h camera, int stream_id, int *interval);
-
-/**
- * @internal
- * @brief Gets the rotation of preview frame.
- * @since_tizen 6.5
- * @remarks The function should be called in camera_preview_cb(),\n
- * otherwise, it will return #CAMERA_ERROR_INVALID_OPERATION.
- * @param[in] camera The handle to the camera
- * @param[out] rotation The rotation of preview frame
- * @return @c 0 on success, otherwise a negative error value
- * @retval #CAMERA_ERROR_NONE Successful
- * @retval #CAMERA_ERROR_INVALID_OPERATION Internal error
- * @retval #CAMERA_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval #CAMERA_ERROR_SERVICE_DISCONNECTED The socket to multimedia server is disconnected
- */
-int camera_attr_get_preview_frame_rotation(camera_h camera, camera_rotation_e *rotation);
-
-/**
* @}
*/
#ifdef __cplusplus
diff --git a/include/camera_private.h b/include/camera_private.h
index 10e0d66..0cece0b 100644
--- a/include/camera_private.h
+++ b/include/camera_private.h
@@ -35,8 +35,8 @@ extern "C" {
#define CAMERA_CB_NETWORK_PREVIEW_TIMEOUT 10
#define CAMERA_CB_NO_TIMEOUT 0
#define CAMERA_FD_INIT -1
+#define CAMERA_IS_FD_VALID(fd) (fd > CAMERA_FD_INIT)
-#define CAMERA_IS_FD_VALID(fd) (fd > CAMERA_FD_INIT)
#define CAMERA_MSG_PARAM_SET(param, msg_type, set_value) { \
param.type = MUSE_TYPE_##msg_type; \
diff --git a/packaging/capi-media-camera.spec b/packaging/capi-media-camera.spec
index 0d543b0..90d2614 100644
--- a/packaging/capi-media-camera.spec
+++ b/packaging/capi-media-camera.spec
@@ -1,7 +1,7 @@
Name: capi-media-camera
Summary: A Camera API
-Version: 0.4.79
-Release: 1
+Version: 0.4.80
+Release: 0
Group: Multimedia/API
License: Apache-2.0
Source0: %{name}-%{version}.tar.gz
diff --git a/src/camera.c b/src/camera.c
index e9ab2eb..73908ee 100644
--- a/src/camera.c
+++ b/src/camera.c
@@ -18,6 +18,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+#include <unistd.h>
#include <mm.h>
#include <mm_types.h>
#include <mm_camcorder.h>
@@ -26,12 +27,27 @@
#include <muse_client.h>
#include <dlog.h>
#include <gio/gio.h>
+#include <dlfcn.h>
#ifdef LOG_TAG
#undef LOG_TAG
#endif
#define LOG_TAG "TIZEN_N_CAMERA"
#define MODULE_NAME "camera"
+#define LIB_CAMERA_DEVICE_MANAGER PATH_LIBDIR"/libcamera_device_manager.so"
+#define CAMERA_CHECK_DEVICE_MANAGER \
+ do {\
+ if (access(LIB_CAMERA_DEVICE_MANAGER, F_OK) != 0) {\
+ CAM_LOG_ERROR("no camera device maanger[errno:%d]", errno);\
+ return CAMERA_ERROR_NOT_SUPPORTED;\
+ }\
+ } while (0)
+
+/* for camera device manager */
+typedef struct _cdm_symbol_table {
+ void **func_ptr;
+ const char *func_name;
+} cdm_symbol_table;
/* for device changed callback */
static GMutex g_cam_dev_state_changed_cb_lock;
@@ -2320,7 +2336,7 @@ int _camera_start_evas_rendering(camera_h camera)
camera_cli_s *pc = (camera_cli_s *)camera;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -2344,7 +2360,7 @@ int _camera_stop_evas_rendering(camera_h camera, bool keep_screen)
camera_cli_s *pc = (camera_cli_s *)camera;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -2621,7 +2637,7 @@ int camera_change_device(camera_h camera, camera_device_e device)
camera_msg_param param;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -2648,7 +2664,7 @@ int camera_destroy(camera_h camera)
camera_cli_s *pc = (camera_cli_s *)camera;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -2682,7 +2698,7 @@ int camera_start_preview(camera_h camera)
camera_state_e current_state = CAMERA_STATE_NONE;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -2763,7 +2779,7 @@ int camera_stop_preview(camera_h camera)
camera_state_e current_state = CAMERA_STATE_NONE;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -2811,7 +2827,7 @@ int camera_start_capture(camera_h camera, camera_capturing_cb capturing_cb, came
muse_camera_api_e api = MUSE_CAMERA_API_START_CAPTURE;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -2838,7 +2854,7 @@ bool camera_is_supported_continuous_capture(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_SUPPORT_CONTINUOUS_CAPTURE;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -2866,7 +2882,7 @@ int camera_start_continuous_capture(camera_h camera, int count, int interval, ca
int value = 0;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -2896,7 +2912,7 @@ int camera_stop_continuous_capture(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_STOP_CONTINUOUS_CAPTURE;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -2917,7 +2933,7 @@ bool camera_is_supported_face_detection(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_SUPPORT_FACE_DETECTION;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -2943,7 +2959,7 @@ bool camera_is_supported_zero_shutter_lag(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_SUPPORT_ZERO_SHUTTER_LAG;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -2969,7 +2985,7 @@ bool camera_is_supported_media_packet_preview_cb(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_SUPPORT_MEDIA_PACKET_PREVIEW_CB;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -2987,6 +3003,33 @@ bool camera_is_supported_media_packet_preview_cb(camera_h camera)
return (bool)ret;
}
+
+bool camera_is_supported_extra_preview(camera_h camera)
+{
+ int ret = CAMERA_ERROR_NONE;
+ camera_cli_s *pc = (camera_cli_s *)camera;
+ muse_camera_api_e api = MUSE_CAMERA_API_SUPPORT_EXTRA_PREVIEW;
+
+ if (!pc || !pc->cb_info) {
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
+ return CAMERA_ERROR_INVALID_PARAMETER;
+ }
+
+ CAM_LOG_INFO("Enter");
+
+ _camera_msg_send(api, NULL, pc->cb_info, &ret, CAMERA_CB_TIMEOUT);
+
+ if (ret < 0) {
+ CAM_LOG_ERROR("error is occurred 0x%x", ret);
+ ret = false;
+ }
+
+ CAM_LOG_INFO("ret : %d", ret);
+
+ return (bool)ret;
+}
+
+
int camera_get_device_count(camera_h camera, int *device_count)
{
int ret = CAMERA_ERROR_NONE;
@@ -2994,7 +3037,7 @@ int camera_get_device_count(camera_h camera, int *device_count)
muse_camera_api_e api = MUSE_CAMERA_API_GET_DEVICE_COUNT;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -3017,7 +3060,7 @@ int camera_start_face_detection(camera_h camera, camera_face_detected_cb callbac
muse_camera_api_e api = MUSE_CAMERA_API_START_FACE_DETECTION;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -3046,7 +3089,7 @@ int camera_stop_face_detection(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_STOP_FACE_DETECTION;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -3100,7 +3143,7 @@ int camera_start_focusing(camera_h camera, bool continuous)
int is_continuous = (int)continuous;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -3122,7 +3165,7 @@ int camera_cancel_focusing(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_CANCEL_FOCUSING;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -3148,7 +3191,7 @@ int _camera_set_display(camera_h camera, mm_display_type_e type, void *display)
muse_camera_display_info_s *dp_info = NULL;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -3268,7 +3311,7 @@ int camera_set_preview_resolution(camera_h camera, int width, int height)
int value = 0;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -3313,7 +3356,7 @@ int camera_set_capture_resolution(camera_h camera, int width, int height)
int value = 0;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -3339,7 +3382,7 @@ int camera_set_capture_format(camera_h camera, camera_pixel_format_e format)
camera_msg_param param;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -3364,7 +3407,7 @@ int camera_set_preview_format(camera_h camera, camera_pixel_format_e format)
muse_camera_api_e api = MUSE_CAMERA_API_SET_PREVIEW_FORMAT;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -3417,7 +3460,7 @@ int camera_set_display_rotation(camera_h camera, camera_rotation_e rotation)
camera_msg_param param;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -3464,7 +3507,7 @@ int camera_set_display_flip(camera_h camera, camera_flip_e flip)
camera_msg_param param;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -3511,7 +3554,7 @@ int camera_set_display_visible(camera_h camera, bool visible)
camera_msg_param param;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -3558,7 +3601,7 @@ int camera_set_display_mode(camera_h camera, camera_display_mode_e mode)
camera_msg_param param;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -3605,7 +3648,7 @@ int camera_set_display_reuse_hint(camera_h camera, bool hint)
camera_msg_param param;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -3776,7 +3819,7 @@ int camera_unset_preview_cb(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_UNSET_PREVIEW_CB;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -3806,7 +3849,7 @@ int camera_set_media_packet_preview_cb(camera_h camera, camera_media_packet_prev
muse_camera_api_e api = MUSE_CAMERA_API_SET_MEDIA_PACKET_PREVIEW_CB;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -3846,7 +3889,7 @@ int camera_unset_media_packet_preview_cb(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_UNSET_MEDIA_PACKET_PREVIEW_CB;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -3911,7 +3954,7 @@ int camera_unset_state_changed_cb(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_UNSET_STATE_CHANGED_CB;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -3971,7 +4014,7 @@ int camera_unset_interrupted_cb(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_UNSET_INTERRUPTED_CB;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4031,7 +4074,7 @@ int camera_unset_interrupt_started_cb(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_UNSET_INTERRUPT_STARTED_CB;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4091,7 +4134,7 @@ int camera_unset_focus_changed_cb(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_UNSET_FOCUS_CHANGED_CB;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4151,7 +4194,7 @@ int camera_unset_error_cb(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_UNSET_ERROR_CB;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4328,7 +4371,7 @@ int camera_attr_set_theater_mode(camera_h camera, camera_attr_theater_mode_e mod
int set_mode = (int)mode;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4401,7 +4444,7 @@ int camera_attr_set_preview_fps(camera_h camera, camera_attr_fps_e fps)
int set_fps = (int)fps;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4425,7 +4468,7 @@ int camera_attr_set_image_quality(camera_h camera, int quality)
camera_msg_param param;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4522,7 +4565,7 @@ int camera_attr_set_encoded_preview_bitrate(camera_h camera, int bitrate)
int set_bitrate = bitrate;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4571,7 +4614,7 @@ int camera_attr_set_encoded_preview_gop_interval(camera_h camera, int interval)
int set_gop_interval = interval;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4595,7 +4638,7 @@ int camera_attr_set_zoom(camera_h camera, int zoom)
camera_msg_param param;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4620,7 +4663,7 @@ int camera_attr_set_af_mode(camera_h camera, camera_attr_af_mode_e mode)
int set_mode = (int)mode;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4643,7 +4686,7 @@ int camera_attr_set_af_area(camera_h camera, int x, int y)
int value = 0;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4667,7 +4710,7 @@ int camera_attr_clear_af_area(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_ATTR_CLEAR_AF_AREA;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4690,7 +4733,7 @@ int camera_attr_set_exposure_mode(camera_h camera, camera_attr_exposure_mode_e m
int set_mode = (int)mode;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4714,7 +4757,7 @@ int camera_attr_set_exposure(camera_h camera, int value)
camera_msg_param param;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4739,7 +4782,7 @@ int camera_attr_set_iso(camera_h camera, camera_attr_iso_e iso)
int set_iso = (int)iso;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4763,7 +4806,7 @@ int camera_attr_set_brightness(camera_h camera, int level)
camera_msg_param param;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4787,7 +4830,7 @@ int camera_attr_set_contrast(camera_h camera, int level)
camera_msg_param param;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4811,7 +4854,7 @@ int camera_attr_set_hue(camera_h camera, int level)
camera_msg_param param;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4836,7 +4879,7 @@ int camera_attr_set_whitebalance(camera_h camera, camera_attr_whitebalance_e wb)
int set_whitebalance = (int)wb;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4861,7 +4904,7 @@ int camera_attr_set_effect(camera_h camera, camera_attr_effect_mode_e effect)
int set_effect = (int)effect;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4886,7 +4929,7 @@ int camera_attr_set_scene_mode(camera_h camera, camera_attr_scene_mode_e mode)
int set_mode = (int)mode;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4911,7 +4954,7 @@ int camera_attr_enable_tag(camera_h camera, bool enable)
int set_enable = (int)enable;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -4960,7 +5003,7 @@ int camera_attr_set_tag_orientation(camera_h camera, camera_attr_tag_orientation
int set_orientation = (int)orientation;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -5011,7 +5054,7 @@ int camera_attr_set_geotag(camera_h camera, double latitude, double longitude, d
int send_ret = 0;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -5060,7 +5103,7 @@ int camera_attr_remove_geotag(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_ATTR_REMOVE_GEOTAG;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -5083,7 +5126,7 @@ int camera_attr_set_flash_mode(camera_h camera, camera_attr_flash_mode_e mode)
int set_mode = (int)mode;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -5944,7 +5987,7 @@ int camera_attr_set_stream_rotation(camera_h camera, camera_rotation_e rotation)
int set_rotation = (int)rotation;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -5993,7 +6036,7 @@ int camera_attr_set_stream_flip(camera_h camera, camera_flip_e flip)
int set_flip = (int)flip;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -6041,7 +6084,7 @@ int camera_attr_set_hdr_mode(camera_h camera, camera_attr_hdr_mode_e mode)
int set_mode = (int)mode;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -6088,7 +6131,7 @@ bool camera_attr_is_supported_hdr_capture(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_ATTR_IS_SUPPORTED_HDR_CAPTURE;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -6114,7 +6157,7 @@ int camera_attr_set_hdr_capture_progress_cb(camera_h camera, camera_attr_hdr_pro
muse_camera_api_e api = MUSE_CAMERA_API_ATTR_SET_HDR_CAPTURE_PROGRESS_CB;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -6154,7 +6197,7 @@ int camera_attr_unset_hdr_capture_progress_cb(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_ATTR_UNSET_HDR_CAPTURE_PROGRESS_CB;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -6186,7 +6229,7 @@ int camera_attr_enable_anti_shake(camera_h camera, bool enable)
int set_enable = (int)enable;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -6233,7 +6276,7 @@ bool camera_attr_is_supported_anti_shake(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_ATTR_IS_SUPPORTED_ANTI_SHAKE;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -6261,7 +6304,7 @@ int camera_attr_enable_video_stabilization(camera_h camera, bool enable)
int set_enable = (int)enable;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -6308,7 +6351,7 @@ bool camera_attr_is_supported_video_stabilization(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_ATTR_IS_SUPPORTED_VIDEO_STABILIZATION;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -6336,7 +6379,7 @@ int camera_attr_enable_auto_contrast(camera_h camera, bool enable)
int set_enable = (int)enable;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -6383,7 +6426,7 @@ bool camera_attr_is_supported_auto_contrast(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_ATTR_IS_SUPPORTED_AUTO_CONTRAST;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -6411,7 +6454,7 @@ int camera_attr_disable_shutter_sound(camera_h camera, bool disable)
int set_disable = (int)disable;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -6436,7 +6479,7 @@ int camera_attr_set_pan(camera_h camera, camera_attr_ptz_move_type_e move_type,
camera_msg_param param1;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -6513,7 +6556,7 @@ int camera_attr_set_tilt(camera_h camera, camera_attr_ptz_move_type_e move_type,
camera_msg_param param1;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -6590,7 +6633,7 @@ int camera_attr_set_ptz_type(camera_h camera, camera_attr_ptz_type_e ptz_type)
int set_ptz_type = (int)ptz_type;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -6641,7 +6684,7 @@ int camera_attr_set_display_roi_area(camera_h camera, int x, int y, int width, i
int send_ret = 0;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -6902,7 +6945,7 @@ int camera_media_bridge_set_bridge(camera_h camera, media_bridge_h bridge)
muse_camera_api_e api = MUSE_CAMERA_API_SET_MEDIA_BRIDGE;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -6938,7 +6981,7 @@ int camera_media_bridge_unset_bridge(camera_h camera)
muse_camera_api_e api = MUSE_CAMERA_API_UNSET_MEDIA_BRIDGE;
if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
return CAMERA_ERROR_INVALID_PARAMETER;
}
@@ -6968,7 +7011,483 @@ _UNSET_MEDIA_BRIDGE_DONE:
//LCOV_EXCL_STOP
+int camera_create_network(camera_device_e device, camera_h *camera)
+{
+ return _camera_create_private(device, true, camera);
+}
+
+
+int camera_device_manager_initialize(camera_device_manager_h *manager)
+{
+ unsigned int i = 0;
+ int ret = CAMERA_ERROR_NONE;
+ void *dl_handle = NULL;
+ camera_device_manager *new_manager = g_new0(camera_device_manager, 1);
+ cdm_symbol_table sym_table[] = {
+ {(void **)&new_manager->initialize, "cdm_initialize"},
+ {(void **)&new_manager->deinitialize, "cdm_deinitialize"},
+ {(void **)&new_manager->get_device_list, "cdm_get_device_list"},
+ {(void **)&new_manager->add_device_connection_changed_cb, "cdm_add_device_connection_changed_cb"},
+ {(void **)&new_manager->remove_device_connection_changed_cb, "cdm_remove_device_connection_changed_cb"},
+ };
+
+ CAMERA_CHECK_DEVICE_MANAGER;
+
+ if (!manager) {
+ CAM_LOG_ERROR("NULL manager");
+ ret = CAMERA_ERROR_INVALID_PARAMETER;
+ goto _INITIALIZE_FAILED;
+ }
+
+ dl_handle = dlopen(LIB_CAMERA_DEVICE_MANAGER, RTLD_NOW);
+ if (!dl_handle) {
+ CAM_LOG_ERROR("dlopen[%s] failed[%s]", LIB_CAMERA_DEVICE_MANAGER, dlerror());
+ ret = CAMERA_ERROR_INVALID_OPERATION;
+ goto _INITIALIZE_FAILED;
+ }
+
+ /* get symbols */
+ for (i = 0 ; i < G_N_ELEMENTS(sym_table) ; i++) {
+ *sym_table[i].func_ptr = dlsym(dl_handle, sym_table[i].func_name);
+ if (*sym_table[i].func_ptr == NULL) {
+ CAM_LOG_ERROR("symbol failed[%s]", sym_table[i].func_name);
+ ret = CAMERA_ERROR_INVALID_OPERATION;
+ goto _INITIALIZE_FAILED;
+ }
+ }
+
+ ret = new_manager->initialize();
+ if (ret != CAMERA_ERROR_NONE) {
+ CAM_LOG_ERROR("failed[0x%x]", ret);
+ goto _INITIALIZE_FAILED;
+ }
+
+ new_manager->dl_handle = dl_handle;
+ *manager = (camera_device_manager_h)new_manager;
+
+ CAM_LOG_INFO("camera device manager[%p](dl handle[%p]) initialized",
+ new_manager, dl_handle);
+
+ return CAMERA_ERROR_NONE;
+
+_INITIALIZE_FAILED:
+ if (dl_handle)
+ dlclose(dl_handle);
+ g_free(new_manager);
+ return ret;
+}
+
+
+//LCOV_EXCL_START
+int camera_device_manager_deinitialize(camera_device_manager_h manager)
+{
+ int ret = CAMERA_ERROR_NONE;
+ camera_device_manager *m = (camera_device_manager *)manager;
+
+ CAMERA_CHECK_DEVICE_MANAGER;
+
+ if (!m) {
+ CAM_LOG_ERROR("NULL manager");
+ return CAMERA_ERROR_INVALID_PARAMETER;
+ }
+
+ CAM_LOG_INFO("deinitialize camera device manager[%p]", m);
+
+ ret = m->deinitialize();
+ if (ret != CAMERA_ERROR_NONE) {
+ CAM_LOG_ERROR("failed[0x%x]", ret);
+ return ret;
+ }
+
+ CAM_LOG_INFO("close dl handle[%p]", m->dl_handle);
+
+ dlclose(m->dl_handle);
+
+ memset(m, 0x0, sizeof(camera_device_manager));
+ g_free(m);
+
+ return CAMERA_ERROR_NONE;
+}
+
+
+int camera_device_manager_foreach_supported_device(camera_device_manager_h manager, camera_supported_device_cb callback, void *user_data)
+{
+ int ret = CAMERA_ERROR_NONE;
+ unsigned int i = 0;
+ camera_device_list_s device_list;
+ camera_device_s *device = NULL;
+ camera_device_manager *m = (camera_device_manager *)manager;
+
+ CAMERA_CHECK_DEVICE_MANAGER;
+
+ if (!m || !callback) {
+ CAM_LOG_ERROR("NULL parameter[%p,%p]", m, callback);
+ return CAMERA_ERROR_INVALID_PARAMETER;
+ }
+
+ CAM_LOG_INFO("enter");
+
+ memset(&device_list, 0x0, sizeof(camera_device_list_s));
+
+ ret = m->get_device_list(&device_list);
+ if (ret != CAMERA_ERROR_NONE) {
+ CAM_LOG_ERROR("failed[0x%x]", ret);
+ return ret;
+ }
+
+ CAM_LOG_INFO("device count[%d]", device_list.count);
+
+ for (i = 0 ; i < device_list.count ; i++) {
+ device = &device_list.device[i];
+
+ CAM_LOG_INFO(" [%d] : type[%d], index[%d], name[%s], id[%s], ex-stream[%d]",
+ i, device->type, device->index,
+ device->name, device->id, device->extra_stream_num);
+
+ if (!callback(device->type, device->index, device->name,
+ device->id, device->extra_stream_num, user_data)) {
+ CAM_LOG_WARNING("callback is stopped[called:%u,total:%u]",
+ i + 1, device_list.count);
+ break;
+ }
+ }
+
+ return CAMERA_ERROR_NONE;
+}
+
+
+int camera_device_manager_add_device_connection_changed_cb(camera_device_manager_h manager,
+ camera_device_connection_changed_cb callback, void *user_data, int *cb_id)
+{
+ int ret = CAMERA_ERROR_NONE;
+ camera_device_manager *m = (camera_device_manager *)manager;
+
+ CAMERA_CHECK_DEVICE_MANAGER;
+
+ if (!m || !callback || !cb_id) {
+ CAM_LOG_ERROR("NULL parameter[%p,%p,%p]", m, callback, cb_id);
+ return CAMERA_ERROR_INVALID_PARAMETER;
+ }
+
+ CAM_LOG_INFO("enter");
+
+ ret = m->add_device_connection_changed_cb(callback, user_data, cb_id);
+ if (ret != CAMERA_ERROR_NONE) {
+ CAM_LOG_ERROR("failed[0x%x]", ret);
+ return ret;
+ }
+
+ CAM_LOG_INFO("cb_id[%d] added", *cb_id);
+
+ return CAMERA_ERROR_NONE;
+}
+
+
+int camera_device_manager_remove_device_connection_changed_cb(camera_device_manager_h manager, int cb_id)
+{
+ int ret = CAMERA_ERROR_NONE;
+ camera_device_manager *m = (camera_device_manager *)manager;
+
+ CAMERA_CHECK_DEVICE_MANAGER;
+
+ if (!m) {
+ CAM_LOG_ERROR("NULL manager");
+ return CAMERA_ERROR_INVALID_PARAMETER;
+ }
+
+ CAM_LOG_INFO("enter - cb_id[%d]", cb_id);
+
+ ret = m->remove_device_connection_changed_cb(cb_id);
+ if (ret != CAMERA_ERROR_NONE) {
+ CAM_LOG_ERROR("failed[0x%x]", ret);
+ return ret;
+ }
+
+ CAM_LOG_INFO("cb_id[%d] removed", cb_id);
+
+ return CAMERA_ERROR_NONE;
+}
+//LCOV_EXCL_STOP
+
+
+int camera_set_extra_preview_cb(camera_h camera, camera_extra_preview_cb callback, void *user_data)
+{
+ int ret = CAMERA_ERROR_NONE;
+ camera_cli_s *pc = (camera_cli_s *)camera;
+ muse_camera_api_e api = MUSE_CAMERA_API_SET_EXTRA_PREVIEW_CB;
+
+ if (!pc || !pc->cb_info || !callback) {
+ CAM_LOG_ERROR("NULL pointer %p %p", pc, callback);
+ return CAMERA_ERROR_INVALID_PARAMETER;
+ }
+
+ CAM_LOG_INFO("Enter");
+
+ _camera_msg_send(api, NULL, pc->cb_info, &ret, CAMERA_CB_TIMEOUT);
+
+ if (ret == CAMERA_ERROR_NONE) {
+ g_mutex_lock(&pc->cb_info->user_cb_mutex[MUSE_CAMERA_EVENT_TYPE_EXTRA_PREVIEW]);
+
+ pc->cb_info->user_cb[MUSE_CAMERA_EVENT_TYPE_EXTRA_PREVIEW] = callback;
+ pc->cb_info->user_data[MUSE_CAMERA_EVENT_TYPE_EXTRA_PREVIEW] = user_data;
+
+ g_mutex_unlock(&pc->cb_info->user_cb_mutex[MUSE_CAMERA_EVENT_TYPE_EXTRA_PREVIEW]);
+ }
+
+ CAM_LOG_INFO("ret : 0x%x", ret);
+
+ return ret;
+}
+
+
+int camera_unset_extra_preview_cb(camera_h camera)
+{
+ int ret = CAMERA_ERROR_NONE;
+ camera_cli_s *pc = (camera_cli_s *)camera;
+ muse_camera_api_e api = MUSE_CAMERA_API_UNSET_EXTRA_PREVIEW_CB;
+
+ if (!pc || !pc->cb_info) {
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
+ return CAMERA_ERROR_INVALID_PARAMETER;
+ }
+
+ CAM_LOG_INFO("Enter");
+
+ _camera_msg_send(api, NULL, pc->cb_info, &ret, CAMERA_CB_TIMEOUT);
+
+ if (ret == CAMERA_ERROR_NONE) {
+ g_mutex_lock(&pc->cb_info->user_cb_mutex[MUSE_CAMERA_EVENT_TYPE_EXTRA_PREVIEW]);
+
+ pc->cb_info->user_cb[MUSE_CAMERA_EVENT_TYPE_EXTRA_PREVIEW] = NULL;
+ pc->cb_info->user_data[MUSE_CAMERA_EVENT_TYPE_EXTRA_PREVIEW] = NULL;
+
+ g_mutex_unlock(&pc->cb_info->user_cb_mutex[MUSE_CAMERA_EVENT_TYPE_EXTRA_PREVIEW]);
+ }
+
+ CAM_LOG_INFO("ret : 0x%x", ret);
+
+ return ret;
+}
+
+
+int camera_set_extra_preview_stream_format(camera_h camera, int stream_id, camera_pixel_format_e pixel_format, int width, int height, int fps)
+{
+ int ret = CAMERA_ERROR_NONE;
+ int send_ret = 0;
+ int stream_format[4] = {pixel_format, width, height, fps};
+ char *msg = NULL;
+ camera_cli_s *pc = (camera_cli_s *)camera;
+ muse_camera_api_e api = MUSE_CAMERA_API_SET_EXTRA_PREVIEW_STREAM_FORMAT;
+
+ if (!pc || !pc->cb_info) {
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
+ return CAMERA_ERROR_INVALID_PARAMETER;
+ }
+
+ CAM_LOG_INFO("Enter - stream[%d],[%d,%dx%d,%d]",
+ stream_id, pixel_format, width, height, fps);
+
+ msg = muse_core_msg_new(api,
+ MUSE_TYPE_INT, "stream_id", stream_id,
+ MUSE_TYPE_ARRAY, "stream_format", 4, stream_format,
+ NULL);
+ if (!msg) {
+ CAM_LOG_ERROR("msg creation failed: api %d", api);
+ return CAMERA_ERROR_OUT_OF_MEMORY;
+ }
+
+ if (pc->cb_info->is_server_connected) {
+ _camera_update_api_waiting(pc->cb_info, api, 1);
+
+ g_mutex_lock(&pc->cb_info->fd_lock);
+ send_ret = muse_core_msg_send(pc->cb_info->fd, msg);
+ g_mutex_unlock(&pc->cb_info->fd_lock);
+ }
+
+ if (send_ret < 0) {
+ CAM_LOG_ERROR("message send failed");
+ ret = CAMERA_ERROR_INVALID_OPERATION;
+ } else {
+ ret = _camera_client_wait_for_cb_return(api, pc->cb_info, CAMERA_CB_TIMEOUT);
+ }
+
+ _camera_update_api_waiting(pc->cb_info, api, -1);
+
+ muse_core_msg_free(msg);
+
+ CAM_LOG_INFO("ret : 0x%x", ret);
+
+ return ret;
+}
+
+
+int camera_get_extra_preview_stream_format(camera_h camera, int stream_id, camera_pixel_format_e *pixel_format, int *width, int *height, int *fps)
+{
+ int ret = CAMERA_ERROR_NONE;
+ camera_cli_s *pc = (camera_cli_s *)camera;
+ camera_msg_param param;
+ muse_camera_api_e api = MUSE_CAMERA_API_GET_EXTRA_PREVIEW_STREAM_FORMAT;
+
+ if (!pc || !pc->cb_info || !pixel_format || !width || !height || !fps) {
+ CAM_LOG_ERROR("NULL pointer %p %p %p %p %p", pc, pixel_format, width, height, fps);
+ return CAMERA_ERROR_INVALID_PARAMETER;
+ }
+
+ CAM_LOG_INFO("Enter - stream[%d]", stream_id);
+
+ CAMERA_MSG_PARAM_SET(param, INT, stream_id);
+
+ _camera_msg_send_param1(api, pc->cb_info, &ret, &param, CAMERA_CB_TIMEOUT);
+
+ if (ret == CAMERA_ERROR_NONE) {
+ *pixel_format = (camera_pixel_format_e)pc->cb_info->get_extra_preview_stream_format[0];
+ *width = pc->cb_info->get_extra_preview_stream_format[1];
+ *height = pc->cb_info->get_extra_preview_stream_format[2];
+ *fps = pc->cb_info->get_extra_preview_stream_format[3];
+ }
+
+ CAM_LOG_INFO("ret : 0x%x", ret);
+
+ return ret;
+}
+
+
+int camera_attr_set_extra_preview_bitrate(camera_h camera, int stream_id, int bitrate)
+{
+ int ret = CAMERA_ERROR_NONE;
+ camera_cli_s *pc = (camera_cli_s *)camera;
+ muse_camera_api_e api = MUSE_CAMERA_API_ATTR_SET_EXTRA_PREVIEW_BITRATE;
+ camera_msg_param param0;
+ camera_msg_param param1;
+
+ if (!pc || !pc->cb_info) {
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
+ return CAMERA_ERROR_INVALID_PARAMETER;
+ }
+
+ CAM_LOG_INFO("Enter - stream[%d], bitrate[%d]", stream_id, bitrate);
+
+ CAMERA_MSG_PARAM_SET(param0, INT, stream_id);
+ CAMERA_MSG_PARAM_SET(param1, INT, bitrate);
+
+ _camera_msg_send_param2_int(api, pc->cb_info, &ret,
+ &param0, &param1, CAMERA_CB_TIMEOUT);
+
+ CAM_LOG_INFO("ret : 0x%x", ret);
+
+ return ret;
+}
+
+
+int camera_attr_get_extra_preview_bitrate(camera_h camera, int stream_id, int *bitrate)
+{
+ int ret = CAMERA_ERROR_NONE;
+ camera_cli_s *pc = (camera_cli_s *)camera;
+ muse_camera_api_e api = MUSE_CAMERA_API_ATTR_GET_EXTRA_PREVIEW_BITRATE;
+ camera_msg_param param;
+
+ if (!pc || !pc->cb_info || !bitrate) {
+ CAM_LOG_ERROR("NULL pointer %p %p", pc, bitrate);
+ return CAMERA_ERROR_INVALID_PARAMETER;
+ }
+
+ CAM_LOG_INFO("Enter - stream[%d]", stream_id);
+
+ CAMERA_MSG_PARAM_SET(param, INT, stream_id);
+
+ _camera_msg_send_param1(api, pc->cb_info, &ret, &param, CAMERA_CB_TIMEOUT);
+
+ if (ret == CAMERA_ERROR_NONE) {
+ *bitrate = pc->cb_info->get_int[MUSE_CAMERA_GET_INT_EXTRA_PREVIEW_BITRATE];
+ CAM_LOG_INFO("get bitrate[%d] for stream[%d]", *bitrate, stream_id);
+ } else {
+ CAM_LOG_ERROR("get bitrate failed for stream[%d] : 0x%x", stream_id, ret);
+ }
+
+ return ret;
+}
+
+
+int camera_attr_set_extra_preview_gop_interval(camera_h camera, int stream_id, int interval)
+{
+ int ret = CAMERA_ERROR_NONE;
+ camera_cli_s *pc = (camera_cli_s *)camera;
+ muse_camera_api_e api = MUSE_CAMERA_API_ATTR_SET_EXTRA_PREVIEW_GOP_INTERVAL;
+ camera_msg_param param0;
+ camera_msg_param param1;
+
+ if (!pc || !pc->cb_info) {
+ CAM_LOG_ERROR("NULL handle[%p]", pc);
+ return CAMERA_ERROR_INVALID_PARAMETER;
+ }
+
+ CAM_LOG_INFO("Enter - stream[%d], GOP interval[%d]", stream_id, interval);
+
+ CAMERA_MSG_PARAM_SET(param0, INT, stream_id);
+ CAMERA_MSG_PARAM_SET(param1, INT, interval);
+
+ _camera_msg_send_param2_int(api, pc->cb_info, &ret,
+ &param0, &param1, CAMERA_CB_TIMEOUT);
+
+ CAM_LOG_INFO("ret : 0x%x", ret);
+
+ return ret;
+}
+
+
+int camera_attr_get_extra_preview_gop_interval(camera_h camera, int stream_id, int *interval)
+{
+ int ret = CAMERA_ERROR_NONE;
+ camera_cli_s *pc = (camera_cli_s *)camera;
+ muse_camera_api_e api = MUSE_CAMERA_API_ATTR_GET_EXTRA_PREVIEW_GOP_INTERVAL;
+ camera_msg_param param;
+
+ if (!pc || !pc->cb_info || !interval) {
+ CAM_LOG_ERROR("NULL pointer %p %p", pc, interval);
+ return CAMERA_ERROR_INVALID_PARAMETER;
+ }
+
+ CAM_LOG_INFO("Enter - stream[%d]", stream_id);
+
+ CAMERA_MSG_PARAM_SET(param, INT, stream_id);
+
+ _camera_msg_send_param1(api, pc->cb_info, &ret, &param, CAMERA_CB_TIMEOUT);
+
+ if (ret == CAMERA_ERROR_NONE) {
+ *interval = pc->cb_info->get_int[MUSE_CAMERA_GET_INT_EXTRA_PREVIEW_GOP_INTERVAL];
+ CAM_LOG_INFO("get GOP interval[%d] for stream[%d]", *interval, stream_id);
+ } else {
+ CAM_LOG_ERROR("get GOP interval failed for stream[%d] : 0x%x", stream_id, ret);
+ }
+
+ return ret;
+}
+
+
+int camera_attr_get_preview_frame_rotation(camera_h camera, camera_rotation_e *rotation)
+{
+ camera_cli_s *pc = (camera_cli_s *)camera;
+
+ if (!pc || !pc->cb_info || !rotation) {
+ CAM_LOG_ERROR("NULL pointer %p %p", pc, rotation);
+ return CAMERA_ERROR_INVALID_PARAMETER;
+ }
+
+ if (!pc->cb_info->stream_data) {
+ CAM_LOG_ERROR("no stream data, maybe it's not in preview callback");
+ return CAMERA_ERROR_INVALID_OPERATION;
+ }
+
+ *rotation = pc->cb_info->stream_data->rotation;
+
+ CAM_LOG_DEBUG("frame rotation[%d]", *rotation);
+
+ return CAMERA_ERROR_NONE;
+}
+
+
int _camera_get_log_level(void)
{
return g_camera_log_level;
}
+
diff --git a/src/camera_internal.c b/src/camera_internal.c
index 9259298..9070f95 100644
--- a/src/camera_internal.c
+++ b/src/camera_internal.c
@@ -23,20 +23,12 @@
#include <camera_internal.h>
#include <camera_private.h>
#include <dlog.h>
-#include <dlfcn.h>
#ifdef LOG_TAG
#undef LOG_TAG
#endif
#define LOG_TAG "TIZEN_N_CAMERA"
-#define LIB_CAMERA_DEVICE_MANAGER PATH_LIBDIR"/libcamera_device_manager.so"
-
-typedef struct _cdm_symbol_table {
- void **func_ptr;
- const char *func_name;
-} cdm_symbol_table;
-
//LCOV_EXCL_START
int camera_start_evas_rendering(camera_h camera)
@@ -208,177 +200,8 @@ void camera_create_preview_frame(MMCamcorderVideoStreamDataType *stream, int num
frame->format, frame->width, frame->height, total_size, frame->num_of_planes);
}
-//LCOV_EXCL_START
-int camera_create_network(camera_device_e device, camera_h *camera)
-{
- return _camera_create_private(device, true, camera);
-}
-
-
-int camera_device_manager_initialize(camera_device_manager_h *manager)
-{
- unsigned int i = 0;
- int ret = CAMERA_ERROR_NONE;
- void *dl_handle = NULL;
- camera_device_manager *new_manager = g_new0(camera_device_manager, 1);
- cdm_symbol_table sym_table[] = {
- {(void **)&new_manager->initialize, "cdm_initialize"},
- {(void **)&new_manager->deinitialize, "cdm_deinitialize"},
- {(void **)&new_manager->get_device_list, "cdm_get_device_list"},
- {(void **)&new_manager->add_device_connection_changed_cb, "cdm_add_device_connection_changed_cb"},
- {(void **)&new_manager->remove_device_connection_changed_cb, "cdm_remove_device_connection_changed_cb"},
- };
-
- if (!manager) {
- CAM_LOG_ERROR("NULL manager");
- ret = CAMERA_ERROR_INVALID_PARAMETER;
- goto _INITIALIZE_FAILED;
- }
-
- dl_handle = dlopen(LIB_CAMERA_DEVICE_MANAGER, RTLD_NOW);
- if (!dl_handle) {
- CAM_LOG_ERROR("dlopen[%s] failed[%s]", LIB_CAMERA_DEVICE_MANAGER, dlerror());
- ret = CAMERA_ERROR_NOT_SUPPORTED;
- goto _INITIALIZE_FAILED;
- }
-
- /* get symbols */
- for (i = 0 ; i < G_N_ELEMENTS(sym_table) ; i++) {
- *sym_table[i].func_ptr = dlsym(dl_handle, sym_table[i].func_name);
- if (*sym_table[i].func_ptr == NULL) {
- CAM_LOG_ERROR("symbol failed[%s]", sym_table[i].func_name);
- ret = CAMERA_ERROR_INVALID_OPERATION;
- goto _INITIALIZE_FAILED;
- }
- }
-
- ret = new_manager->initialize();
- if (ret != CAMERA_ERROR_NONE) {
- CAM_LOG_ERROR("failed[0x%x]", ret);
- goto _INITIALIZE_FAILED;
- }
-
- new_manager->dl_handle = dl_handle;
- *manager = (camera_device_manager_h)new_manager;
-
- CAM_LOG_INFO("camera device manager[%p]", new_manager);
-
- return CAMERA_ERROR_NONE;
-
-_INITIALIZE_FAILED:
- if (dl_handle)
- dlclose(dl_handle);
- g_free(new_manager);
- return ret;
-}
-
-
-int camera_device_manager_deinitialize(camera_device_manager_h manager)
-{
- int ret = CAMERA_ERROR_NONE;
- camera_device_manager *m = (camera_device_manager *)manager;
-
- if (!m) {
- CAM_LOG_ERROR("NULL manager");
- return CAMERA_ERROR_INVALID_PARAMETER;
- }
-
- ret = m->deinitialize();
- if (ret != CAMERA_ERROR_NONE) {
- CAM_LOG_ERROR("failed[0x%x]", ret);
- return ret;
- }
-
- dlclose(m->dl_handle);
- memset(m, 0x0, sizeof(camera_device_manager));
- g_free(m);
-
- CAM_LOG_INFO("finalized");
-
- return CAMERA_ERROR_NONE;
-}
-
-
-int camera_device_manager_get_device_list(camera_device_manager_h manager, camera_device_list_s *list)
-{
- int ret = CAMERA_ERROR_NONE;
- unsigned int i = 0;
- camera_device_manager *m = (camera_device_manager *)manager;
-
- if (!m || !list) {
- CAM_LOG_ERROR("NULL parameter[%p,%p]", m, list);
- return CAMERA_ERROR_INVALID_PARAMETER;
- }
-
- CAM_LOG_INFO("enter");
-
- ret = m->get_device_list(list);
- if (ret != CAMERA_ERROR_NONE) {
- CAM_LOG_ERROR("failed[0x%x]", ret);
- return ret;
- }
-
- CAM_LOG_INFO("device count[%d]", list->count);
-
- for (i = 0 ; i < list->count ; i++) {
- CAM_LOG_INFO(" [%d] : type[%d], device index[%d], name[%s], id[%s]",
- i, list->device[i].type, list->device[i].index,
- list->device[i].name, list->device[i].id);
- }
-
- return CAMERA_ERROR_NONE;
-}
-
-
-int camera_device_manager_add_device_connection_changed_cb(camera_device_manager_h manager,
- camera_device_connection_changed_cb callback, void *user_data, int *cb_id)
-{
- int ret = CAMERA_ERROR_NONE;
- camera_device_manager *m = (camera_device_manager *)manager;
-
- if (!m || !callback || !cb_id) {
- CAM_LOG_ERROR("NULL parameter[%p,%p,%p]", m, callback, cb_id);
- return CAMERA_ERROR_INVALID_PARAMETER;
- }
-
- CAM_LOG_INFO("enter");
-
- ret = m->add_device_connection_changed_cb(callback, user_data, cb_id);
- if (ret != CAMERA_ERROR_NONE) {
- CAM_LOG_ERROR("failed[0x%x]", ret);
- return ret;
- }
-
- CAM_LOG_INFO("cb_id[%d] added", *cb_id);
-
- return CAMERA_ERROR_NONE;
-}
-
-
-int camera_device_manager_remove_device_connection_changed_cb(camera_device_manager_h manager, int cb_id)
-{
- int ret = CAMERA_ERROR_NONE;
- camera_device_manager *m = (camera_device_manager *)manager;
-
- if (!m) {
- CAM_LOG_ERROR("NULL manager");
- return CAMERA_ERROR_INVALID_PARAMETER;
- }
-
- CAM_LOG_INFO("enter - cb_id[%d]", cb_id);
-
- ret = m->remove_device_connection_changed_cb(cb_id);
- if (ret != CAMERA_ERROR_NONE) {
- CAM_LOG_ERROR("failed[0x%x]", ret);
- return ret;
- }
-
- CAM_LOG_INFO("cb_id[%d] removed", cb_id);
-
- return CAMERA_ERROR_NONE;
-}
-
+//LCOV_EXCL_START
int camera_attr_set_flash_brightness(camera_h camera, int level)
{
int ret = CAMERA_ERROR_NONE;
@@ -525,281 +348,4 @@ int camera_attr_get_focus_level_range(camera_h camera, int *min, int *max)
return ret;
}
-
-
-int camera_set_extra_preview_cb(camera_h camera, camera_extra_preview_cb callback, void *user_data)
-{
- int ret = CAMERA_ERROR_NONE;
- camera_cli_s *pc = (camera_cli_s *)camera;
- muse_camera_api_e api = MUSE_CAMERA_API_SET_EXTRA_PREVIEW_CB;
-
- if (!pc || !pc->cb_info || !callback) {
- CAM_LOG_ERROR("NULL pointer %p %p", pc, callback);
- return CAMERA_ERROR_INVALID_PARAMETER;
- }
-
- CAM_LOG_INFO("Enter");
-
- _camera_msg_send(api, NULL, pc->cb_info, &ret, CAMERA_CB_TIMEOUT);
-
- if (ret == CAMERA_ERROR_NONE) {
- g_mutex_lock(&pc->cb_info->user_cb_mutex[MUSE_CAMERA_EVENT_TYPE_EXTRA_PREVIEW]);
-
- pc->cb_info->user_cb[MUSE_CAMERA_EVENT_TYPE_EXTRA_PREVIEW] = callback;
- pc->cb_info->user_data[MUSE_CAMERA_EVENT_TYPE_EXTRA_PREVIEW] = user_data;
-
- g_mutex_unlock(&pc->cb_info->user_cb_mutex[MUSE_CAMERA_EVENT_TYPE_EXTRA_PREVIEW]);
- }
-
- CAM_LOG_INFO("ret : 0x%x", ret);
-
- return ret;
-}
-
-
-int camera_unset_extra_preview_cb(camera_h camera)
-{
- int ret = CAMERA_ERROR_NONE;
- camera_cli_s *pc = (camera_cli_s *)camera;
- muse_camera_api_e api = MUSE_CAMERA_API_UNSET_EXTRA_PREVIEW_CB;
-
- if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
- return CAMERA_ERROR_INVALID_PARAMETER;
- }
-
- CAM_LOG_INFO("Enter");
-
- _camera_msg_send(api, NULL, pc->cb_info, &ret, CAMERA_CB_TIMEOUT);
-
- if (ret == CAMERA_ERROR_NONE) {
- g_mutex_lock(&pc->cb_info->user_cb_mutex[MUSE_CAMERA_EVENT_TYPE_EXTRA_PREVIEW]);
-
- pc->cb_info->user_cb[MUSE_CAMERA_EVENT_TYPE_EXTRA_PREVIEW] = NULL;
- pc->cb_info->user_data[MUSE_CAMERA_EVENT_TYPE_EXTRA_PREVIEW] = NULL;
-
- g_mutex_unlock(&pc->cb_info->user_cb_mutex[MUSE_CAMERA_EVENT_TYPE_EXTRA_PREVIEW]);
- }
-
- CAM_LOG_INFO("ret : 0x%x", ret);
-
- return ret;
-}
-
-
-int camera_set_extra_preview_stream_format(camera_h camera, int stream_id, camera_pixel_format_e pixel_format, int width, int height, int fps)
-{
- int ret = CAMERA_ERROR_NONE;
- int send_ret = 0;
- int stream_format[4] = {pixel_format, width, height, fps};
- char *msg = NULL;
- camera_cli_s *pc = (camera_cli_s *)camera;
- muse_camera_api_e api = MUSE_CAMERA_API_SET_EXTRA_PREVIEW_STREAM_FORMAT;
-
- if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
- return CAMERA_ERROR_INVALID_PARAMETER;
- }
-
- CAM_LOG_INFO("Enter - stream[%d],[%d,%dx%d,%d]",
- stream_id, pixel_format, width, height, fps);
-
- msg = muse_core_msg_new(api,
- MUSE_TYPE_INT, "stream_id", stream_id,
- MUSE_TYPE_ARRAY, "stream_format", 4, stream_format,
- NULL);
- if (!msg) {
- CAM_LOG_ERROR("msg creation failed: api %d", api);
- return CAMERA_ERROR_OUT_OF_MEMORY;
- }
-
- if (pc->cb_info->is_server_connected) {
- _camera_update_api_waiting(pc->cb_info, api, 1);
-
- g_mutex_lock(&pc->cb_info->fd_lock);
- send_ret = muse_core_msg_send(pc->cb_info->fd, msg);
- g_mutex_unlock(&pc->cb_info->fd_lock);
- }
-
- if (send_ret < 0) {
- CAM_LOG_ERROR("message send failed");
- ret = CAMERA_ERROR_INVALID_OPERATION;
- } else {
- ret = _camera_client_wait_for_cb_return(api, pc->cb_info, CAMERA_CB_TIMEOUT);
- }
-
- _camera_update_api_waiting(pc->cb_info, api, -1);
-
- muse_core_msg_free(msg);
-
- CAM_LOG_INFO("ret : 0x%x", ret);
-
- return ret;
-}
-
-
-int camera_get_extra_preview_stream_format(camera_h camera, int stream_id, camera_pixel_format_e *pixel_format, int *width, int *height, int *fps)
-{
- int ret = CAMERA_ERROR_NONE;
- camera_cli_s *pc = (camera_cli_s *)camera;
- camera_msg_param param;
- muse_camera_api_e api = MUSE_CAMERA_API_GET_EXTRA_PREVIEW_STREAM_FORMAT;
-
- if (!pc || !pc->cb_info || !pixel_format || !width || !height || !fps) {
- CAM_LOG_ERROR("NULL pointer %p %p %p %p %p", pc, pixel_format, width, height, fps);
- return CAMERA_ERROR_INVALID_PARAMETER;
- }
-
- CAM_LOG_INFO("Enter - stream[%d]", stream_id);
-
- CAMERA_MSG_PARAM_SET(param, INT, stream_id);
-
- _camera_msg_send_param1(api, pc->cb_info, &ret, &param, CAMERA_CB_TIMEOUT);
-
- if (ret == CAMERA_ERROR_NONE) {
- *pixel_format = (camera_pixel_format_e)pc->cb_info->get_extra_preview_stream_format[0];
- *width = pc->cb_info->get_extra_preview_stream_format[1];
- *height = pc->cb_info->get_extra_preview_stream_format[2];
- *fps = pc->cb_info->get_extra_preview_stream_format[3];
- }
-
- CAM_LOG_INFO("ret : 0x%x", ret);
-
- return ret;
-}
-
-
-int camera_attr_set_extra_preview_bitrate(camera_h camera, int stream_id, int bitrate)
-{
- int ret = CAMERA_ERROR_NONE;
- camera_cli_s *pc = (camera_cli_s *)camera;
- muse_camera_api_e api = MUSE_CAMERA_API_ATTR_SET_EXTRA_PREVIEW_BITRATE;
- camera_msg_param param0;
- camera_msg_param param1;
-
- if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
- return CAMERA_ERROR_INVALID_PARAMETER;
- }
-
- CAM_LOG_INFO("Enter - stream[%d], bitrate[%d]", stream_id, bitrate);
-
- CAMERA_MSG_PARAM_SET(param0, INT, stream_id);
- CAMERA_MSG_PARAM_SET(param1, INT, bitrate);
-
- _camera_msg_send_param2_int(api, pc->cb_info, &ret,
- &param0, &param1, CAMERA_CB_TIMEOUT);
-
- CAM_LOG_INFO("ret : 0x%x", ret);
-
- return ret;
-}
-
-
-int camera_attr_get_extra_preview_bitrate(camera_h camera, int stream_id, int *bitrate)
-{
- int ret = CAMERA_ERROR_NONE;
- camera_cli_s *pc = (camera_cli_s *)camera;
- muse_camera_api_e api = MUSE_CAMERA_API_ATTR_GET_EXTRA_PREVIEW_BITRATE;
- camera_msg_param param;
-
- if (!pc || !pc->cb_info || !bitrate) {
- CAM_LOG_ERROR("NULL pointer %p %p", pc, bitrate);
- return CAMERA_ERROR_INVALID_PARAMETER;
- }
-
- CAM_LOG_INFO("Enter - stream[%d]", stream_id);
-
- CAMERA_MSG_PARAM_SET(param, INT, stream_id);
-
- _camera_msg_send_param1(api, pc->cb_info, &ret, &param, CAMERA_CB_TIMEOUT);
-
- if (ret == CAMERA_ERROR_NONE) {
- *bitrate = pc->cb_info->get_int[MUSE_CAMERA_GET_INT_EXTRA_PREVIEW_BITRATE];
- CAM_LOG_INFO("get bitrate[%d] for stream[%d]", *bitrate, stream_id);
- } else {
- CAM_LOG_ERROR("get bitrate failed for stream[%d] : 0x%x", stream_id, ret);
- }
-
- return ret;
-}
-
-
-int camera_attr_set_extra_preview_gop_interval(camera_h camera, int stream_id, int interval)
-{
- int ret = CAMERA_ERROR_NONE;
- camera_cli_s *pc = (camera_cli_s *)camera;
- muse_camera_api_e api = MUSE_CAMERA_API_ATTR_SET_EXTRA_PREVIEW_GOP_INTERVAL;
- camera_msg_param param0;
- camera_msg_param param1;
-
- if (!pc || !pc->cb_info) {
- CAM_LOG_ERROR("NULL handle");
- return CAMERA_ERROR_INVALID_PARAMETER;
- }
-
- CAM_LOG_INFO("Enter - stream[%d], GOP interval[%d]", stream_id, interval);
-
- CAMERA_MSG_PARAM_SET(param0, INT, stream_id);
- CAMERA_MSG_PARAM_SET(param1, INT, interval);
-
- _camera_msg_send_param2_int(api, pc->cb_info, &ret,
- &param0, &param1, CAMERA_CB_TIMEOUT);
-
- CAM_LOG_INFO("ret : 0x%x", ret);
-
- return ret;
-}
-
-
-int camera_attr_get_extra_preview_gop_interval(camera_h camera, int stream_id, int *interval)
-{
- int ret = CAMERA_ERROR_NONE;
- camera_cli_s *pc = (camera_cli_s *)camera;
- muse_camera_api_e api = MUSE_CAMERA_API_ATTR_GET_EXTRA_PREVIEW_GOP_INTERVAL;
- camera_msg_param param;
-
- if (!pc || !pc->cb_info || !interval) {
- CAM_LOG_ERROR("NULL pointer %p %p", pc, interval);
- return CAMERA_ERROR_INVALID_PARAMETER;
- }
-
- CAM_LOG_INFO("Enter - stream[%d]", stream_id);
-
- CAMERA_MSG_PARAM_SET(param, INT, stream_id);
-
- _camera_msg_send_param1(api, pc->cb_info, &ret, &param, CAMERA_CB_TIMEOUT);
-
- if (ret == CAMERA_ERROR_NONE) {
- *interval = pc->cb_info->get_int[MUSE_CAMERA_GET_INT_EXTRA_PREVIEW_GOP_INTERVAL];
- CAM_LOG_INFO("get GOP interval[%d] for stream[%d]", *interval, stream_id);
- } else {
- CAM_LOG_ERROR("get GOP interval failed for stream[%d] : 0x%x", stream_id, ret);
- }
-
- return ret;
-}
-
-
-int camera_attr_get_preview_frame_rotation(camera_h camera, camera_rotation_e *rotation)
-{
- camera_cli_s *pc = (camera_cli_s *)camera;
-
- if (!pc || !pc->cb_info || !rotation) {
- CAM_LOG_ERROR("NULL pointer %p %p", pc, rotation);
- return CAMERA_ERROR_INVALID_PARAMETER;
- }
-
- if (!pc->cb_info->stream_data) {
- CAM_LOG_ERROR("no stream data, maybe it's not in preview callback");
- return CAMERA_ERROR_INVALID_OPERATION;
- }
-
- *rotation = pc->cb_info->stream_data->rotation;
-
- CAM_LOG_DEBUG("frame rotation[%d]", *rotation);
-
- return CAMERA_ERROR_NONE;
-}
-
//LCOV_EXCL_STOP
diff --git a/test/camera_test.c b/test/camera_test.c
index a60ef02..e4edee5 100644
--- a/test/camera_test.c
+++ b/test/camera_test.c
@@ -125,14 +125,14 @@ static media_bridge_h bridge;
#define SENSOR_WHITEBALANCE_NUM 10
#define SENSOR_COLOR_TONE_NUM 31
-#define SENSOR_FLIP_NUM 4
+#define SENSOR_FLIP_NUM 4
#define SENSOR_PROGRAM_MODE_NUM 15
-#define SENSOR_FOCUS_NUM 6
+#define SENSOR_FOCUS_NUM 6
#define SENSOR_INPUT_ROTATION 4
-#define SENSOR_AF_SCAN_NUM 4
-#define SENSOR_ISO_NUM 8
-#define SENSOR_EXPOSURE_NUM 9
-#define SENSOR_IMAGE_FORMAT 20
+#define SENSOR_AF_SCAN_NUM 4
+#define SENSOR_ISO_NUM 8
+#define SENSOR_EXPOSURE_NUM 9
+#define SENSOR_IMAGE_FORMAT 20
/*-----------------------------------------------------------------------
@@ -149,7 +149,7 @@ enum {
MENU_STATE_MAIN,
MENU_STATE_MAIN_SETTING,
MENU_STATE_DEVICE_STATE,
- MENU_STATE_DEVICE_LIST,
+ MENU_STATE_DEVICE_MANAGER,
MENU_STATE_NUM,
};
@@ -473,15 +473,20 @@ static void _camera_device_state_changed_cb(camera_device_e device, camera_devic
g_print("\n\tcamera device[%d] state changed to %d\n", device, state);
}
-static void _camera_device_connection_changed_cb(camera_device_s *device, bool is_connected, void *user_data)
+static void _camera_device_connection_changed_cb(camera_device_type_e type, camera_device_e device,
+ const char *name, const char *id, int extra_preview_stream_num, bool is_connected, void *user_data)
{
- if (!device) {
- g_print("NULL list");
- return;
- }
+ g_print("\n\tcamera device changed[is_connected:%d][Type:%d,index:%d,name:%s,id:%s,exstream:%d]\n",
+ is_connected, type, device, name, id, extra_preview_stream_num);
+}
+
+static bool _camera_supported_device_cb(camera_device_type_e type, camera_device_e device,
+ const char *name, const char *id, int extra_preview_stream_num, void *user_data)
+{
+ g_print("\n\tcamera supported device[Type:%d,index:%d,name:%s,id:%s,exstream:%d]\n",
+ type, device, name, id, extra_preview_stream_num);
- g_print("\n\tcamera device changed[is_connected:%d][Type:%d,index:%d,name:%s,id:%s,exstreamnum:%d]\n",
- is_connected, device->type, device->index, device->name, device->id, device->extra_stream_num);
+ return true;
}
static void _camera_interrupted_cb(camera_policy_e policy, camera_state_e previous, camera_state_e current, void *user_data)
@@ -906,7 +911,7 @@ static void print_menu()
g_print("\t=======================================\n");
g_print("\t '1' Video Capture\n");
g_print("\t '2' Device State\n");
- g_print("\t '3' Device List\n");
+ g_print("\t '3' Device Manager\n");
g_print("\t 'q' Exit\n");
g_print("\t=======================================\n");
break;
@@ -934,12 +939,12 @@ static void print_menu()
g_print("\t 'b' back\n");
g_print("\t=======================================\n");
break;
- case MENU_STATE_DEVICE_LIST:
+ case MENU_STATE_DEVICE_MANAGER:
g_print("\n\t=======================================\n");
g_print("\t Device List\n");
g_print("\t=======================================\n");
g_print("\t '1' Initialize device manager\n");
- g_print("\t '2' Get camera device list\n");
+ g_print("\t '2' Foreach supported camera device\n");
g_print("\t '3' Add camera device connection changed callback\n");
g_print("\t '4' Remove camera device connection changed callback\n");
g_print("\t '9' Deinitialize device manager\n");
@@ -1781,11 +1786,9 @@ static void device_state_menu(gchar buf)
}
}
-static void device_list_menu(gchar buf)
+static void device_manager_menu(gchar buf)
{
int ret = 0;
- unsigned int i = 0;
- camera_device_list_s device_list;
switch (buf) {
case '1': /* Initialize device manager */
@@ -1793,21 +1796,12 @@ static void device_list_menu(gchar buf)
g_print("\n\tDevice manager[%p] initialize result[0x%x]\n",
g_device_manager, ret);
break;
- case '2': /* Get device list */
- memset(&device_list, 0x0, sizeof(camera_device_list_s));
- ret = camera_device_manager_get_device_list(g_device_manager, &device_list);
+ case '2': /* Foreach supported camera device */
+ ret = camera_device_manager_foreach_supported_device(g_device_manager, _camera_supported_device_cb, NULL);
if (ret != CAMERA_ERROR_NONE) {
g_print("\n\tGet device list failed[0x%x]\n", ret);
return;
}
-
- g_print("\n\tDevice list[count:%d]\n", device_list.count);
-
- for (i = 0 ; i < device_list.count ; i++) {
- g_print("\t[%d] : type[%d], index[%d], name[%s], id[%s]\n",
- i, device_list.device[i].type, device_list.device[i].index,
- device_list.device[i].name, device_list.device[i].id);
- }
break;
case '3': /* Add device connection changed callback */
ret = camera_device_manager_add_device_connection_changed_cb(g_device_manager,
@@ -1881,8 +1875,8 @@ static gboolean cmd_input(GIOChannel *channel, GIOCondition condition, gpointer
case MENU_STATE_DEVICE_STATE:
device_state_menu(buf[0]);
break;
- case MENU_STATE_DEVICE_LIST:
- device_list_menu(buf[0]);
+ case MENU_STATE_DEVICE_MANAGER:
+ device_manager_menu(buf[0]);
break;
default:
break;
@@ -1966,7 +1960,7 @@ static gboolean mode_change(gchar buf)
hcamcorder->menu_state = MENU_STATE_DEVICE_STATE;
return TRUE;
case '3':
- hcamcorder->menu_state = MENU_STATE_DEVICE_LIST;
+ hcamcorder->menu_state = MENU_STATE_DEVICE_MANAGER;
return TRUE;
case 'q':
g_print("\t Quit Camcorder Testsuite!!\n");
diff --git a/test_headless/camera_test_headless.c b/test_headless/camera_test_headless.c
index 8695fc1..9cdade1 100644
--- a/test_headless/camera_test_headless.c
+++ b/test_headless/camera_test_headless.c
@@ -120,7 +120,7 @@ static media_bridge_h bridge;
-----------------------------------------------------------------------*/
enum {
MODE_VIDEO_CAPTURE, /* recording and image capture mode */
- MODE_AUDIO, /* audio recording*/
+ MODE_AUDIO, /* audio recording*/
MODE_NUM,
};
@@ -129,7 +129,7 @@ enum {
MENU_STATE_MAIN,
MENU_STATE_MAIN_SETTING,
MENU_STATE_DEVICE_STATE,
- MENU_STATE_DEVICE_LIST,
+ MENU_STATE_DEVICE_MANAGER,
MENU_STATE_NUM,
};
@@ -139,10 +139,10 @@ enum {
typedef struct _cam_handle {
camera_h camera;
int type;
- int is_multishot; /* flag for multishot mode */
- int stillshot_count; /* stillshot count */
- int multishot_count; /* multishot count */
- char file_path[MAX_FILE_PATH_LENGTH]; /* file path for captured data */
+ int is_multishot; /* flag for multishot mode */
+ int stillshot_count; /* stillshot count */
+ int multishot_count; /* multishot count */
+ char file_path[MAX_FILE_PATH_LENGTH]; /* file path for captured data */
int menu_state;
unsigned long long elapsed_time;
} cam_handle_t;
@@ -453,15 +453,20 @@ static void _camera_device_state_changed_cb(camera_device_e device, camera_devic
g_print("\n\tcamera device[%d] state changed to %d\n", device, state);
}
-static void _camera_device_connection_changed_cb(camera_device_s *device, bool is_connected, void *user_data)
+static void _camera_device_connection_changed_cb(camera_device_type_e type, camera_device_e device,
+ const char *name, const char *id, int extra_preview_stream_num, bool is_connected, void *user_data)
{
- if (!device) {
- g_print("NULL list");
- return;
- }
+ g_print("\n\tcamera device changed[is_connected:%d][Type:%d,index:%d,name:%s,id:%s,exstream:%d]\n",
+ is_connected, type, device, name, id, extra_preview_stream_num);
+}
- g_print("\n\tcamera device changed[is_connected:%d][Type:%d,index:%d,name:%s,id:%s,exstreamnum:%d]\n",
- is_connected, device->type, device->index, device->name, device->id, device->extra_stream_num);
+static bool _camera_supported_device_cb(camera_device_type_e type, camera_device_e device,
+ const char *name, const char *id, int extra_preview_stream_num, void *user_data)
+{
+ g_print("\n\tcamera supported device[Type:%d,index:%d,name:%s,id:%s,exstream:%d]\n",
+ type, device, name, id, extra_preview_stream_num);
+
+ return true;
}
static void _camera_interrupted_cb(camera_policy_e policy, camera_state_e previous, camera_state_e current, void *user_data)
@@ -712,7 +717,6 @@ _MEDIA_PACKET_PREVIEW_CB_OUT:
media_packet_unref(pkt);
}
-
static bool preview_resolution_cb(int width, int height, void *user_data)
{
resolution_stack *data = (resolution_stack *)user_data;
@@ -887,7 +891,7 @@ static void print_menu()
g_print("\t=======================================\n");
g_print("\t '1' Video Capture\n");
g_print("\t '2' Device State\n");
- g_print("\t '3' Device List\n");
+ g_print("\t '3' Device Manager\n");
g_print("\t 'q' Exit\n");
g_print("\t=======================================\n");
break;
@@ -915,12 +919,12 @@ static void print_menu()
g_print("\t 'b' back\n");
g_print("\t=======================================\n");
break;
- case MENU_STATE_DEVICE_LIST:
+ case MENU_STATE_DEVICE_MANAGER:
g_print("\n\t=======================================\n");
g_print("\t Device List\n");
g_print("\t=======================================\n");
g_print("\t '1' Initialize device manager\n");
- g_print("\t '2' Get camera device list\n");
+ g_print("\t '2' Foreach supported camera device\n");
g_print("\t '3' Add camera device connection changed callback\n");
g_print("\t '4' Remove camera device connection changed callback\n");
g_print("\t '9' Deinitialize device manager\n");
@@ -1762,11 +1766,9 @@ static void device_state_menu(gchar buf)
}
}
-static void device_list_menu(gchar buf)
+static void device_manager_menu(gchar buf)
{
int ret = 0;
- unsigned int i = 0;
- camera_device_list_s device_list;
switch (buf) {
case '1': /* Initialize device manager */
@@ -1774,21 +1776,12 @@ static void device_list_menu(gchar buf)
g_print("\n\tDevice manager[%p] initialize result[0x%x]\n",
g_device_manager, ret);
break;
- case '2': /* Get device list */
- memset(&device_list, 0x0, sizeof(camera_device_list_s));
- ret = camera_device_manager_get_device_list(g_device_manager, &device_list);
+ case '2': /* Foreach supported camera device */
+ ret = camera_device_manager_foreach_supported_device(g_device_manager, _camera_supported_device_cb, NULL);
if (ret != CAMERA_ERROR_NONE) {
g_print("\n\tGet device list failed[0x%x]\n", ret);
return;
}
-
- g_print("\n\tDevice list[count:%d]\n", device_list.count);
-
- for (i = 0 ; i < device_list.count ; i++) {
- g_print("\t[%d] : type[%d], index[%d], name[%s], id[%s]\n",
- i, device_list.device[i].type, device_list.device[i].index,
- device_list.device[i].name, device_list.device[i].id);
- }
break;
case '3': /* Add device connection changed callback */
ret = camera_device_manager_add_device_connection_changed_cb(g_device_manager,
@@ -1862,8 +1855,8 @@ static gboolean cmd_input(GIOChannel *channel, GIOCondition condition, gpointer
case MENU_STATE_DEVICE_STATE:
device_state_menu(buf[0]);
break;
- case MENU_STATE_DEVICE_LIST:
- device_list_menu(buf[0]);
+ case MENU_STATE_DEVICE_MANAGER:
+ device_manager_menu(buf[0]);
break;
default:
break;
@@ -1945,7 +1938,7 @@ static gboolean mode_change(gchar buf)
hcamcorder->menu_state = MENU_STATE_DEVICE_STATE;
return TRUE;
case '3':
- hcamcorder->menu_state = MENU_STATE_DEVICE_LIST;
+ hcamcorder->menu_state = MENU_STATE_DEVICE_MANAGER;
return TRUE;
case 'q':
g_print("\t Quit Camcorder Testsuite!!\n");