fixup! Fix improper function reference
[platform/core/api/sound-manager.git] / include / sound_manager_internal.h
index db40ebe..e684544 100644 (file)
@@ -213,7 +213,7 @@ int sound_manager_get_mute(sound_type_e type, bool *muted);
  * @see sound_manager_remove_all_devices_for_stream_routing()
  * @see sound_manager_apply_stream_routing()
  * @see sound_manager_acquire_focus()
- * @see sound_manager_destroy_focus()
+ * @see sound_manager_release_focus()
  * @see sound_manager_get_focus_state()
  */
 int sound_manager_create_stream_information_internal(sound_stream_type_internal_e stream_type, sound_stream_focus_state_changed_cb callback, void *user_data, sound_stream_info_h *stream_info);
@@ -341,6 +341,39 @@ int sound_manager_remove_device_id_for_stream_routing(sound_stream_info_h stream
 
 /**
  * @internal
+ * @brief Sets the preferred built-in device id for the stream routing.
+ * @since_tizen 5.5
+ *
+ * @remarks    This function is to set a specific built-in device id when the system has multiple devices of the same built-in device type.
+ *     When there's only one device for a built-in device type in the system, nothing will happen even if this function succeeds in operation.
+ *     If the device type of @a device_id is not supported by @a stream_info, #SOUND_MANAGER_ERROR_POLICY will be returned.
+ *
+ * @param[in]  stream_info     The handle of stream information
+ * @param[in]  io_direction    The IO direction of the device
+ * @param[in]  device_id       The preferred device id (this can be #SOUND_MANAGER_STREAM_NO_PREFERRED_DEVICE to unset)
+ * @return @c 0 on success,
+ *         otherwise a negative error value
+ * @retval #SOUND_MANAGER_ERROR_NONE Success
+ * @retval #SOUND_MANAGER_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #SOUND_MANAGER_ERROR_POLICY Noncompliance with the sound system policy
+ * @retval #SOUND_MANAGER_ERROR_INTERNAL Internal error inside the sound system
+ * @pre Call sound_manager_create_stream_information() before calling this function.
+ * @pre Get a device by calling sound_manager_get_device_list() and sound_manager_get_next_device().
+ * @pre Get a device id by calling sound_manager_get_device_id().
+ * @post You can get preferred devices by calling sound_manager_get_stream_preferred_device().
+ * @post Call sound_manager_free_device_list() to free the devices.
+ * @see sound_manager_get_stream_preferred_device()
+ * @see sound_manager_create_stream_information()
+ * @see sound_manager_destroy_stream_information()
+ * @see sound_manager_get_device_list()
+ * @see sound_manager_get_next_device()
+ * @see sound_manager_get_device_id()
+ * @see sound_manager_free_device_list()
+ */
+int sound_manager_set_stream_preferred_device_id(sound_stream_info_h stream_info, sound_device_io_direction_e io_direction, int device_id);
+
+/**
+ * @internal
  * @brief Gets the state of the device by id.
  * @since_tizen 4.0
  * @param[in]  device_id       The device id