*/
bool _check_enabled_user_cb_lock(int event_id);
+/**
+ * @brief Sets the audio only mode.
+ * @since_tizen 4.0
+ * @details This function is used to disable or enable video rendering during playback.
+ * @param[in] player The handle to the media player
+ * @param[in] audio_only The new audio only status: (@c true = enable audio only, @c false = disable audio only)
+ * @return @c 0 on success,
+ * otherwise a negative error value
+ * @retval #PLAYER_ERROR_NONE Successful
+ * @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation
+ * @retval #PLAYER_ERROR_INVALID_STATE Invalid player state
+ * @pre The player state must be one of: #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED.
+ * @see player_is_audio_only()
+ */
+int legacy_player_set_audio_only(player_h player, bool audio_only);
+
+/**
+ * @brief Gets the audio only mode status.
+ * @since_tizen 4.0
+ * @param[in] player The handle to the media player
+ * @param[out] paudio_only The current audio only status: (@c true = audio only enabled, @c false = audio only disabled)
+ * @return @c 0 on success,
+ * otherwise a negative error value
+ * @retval #PLAYER_ERROR_NONE Successful
+ * @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation
+ * @pre The player state must be one of: #PLAYER_STATE_IDLE, #PLAYER_STATE_READY, #PLAYER_STATE_PLAYING, or #PLAYER_STATE_PAUSED.
+ * @see player_set_audio_only()
+ */
+int legacy_player_is_audio_only(player_h player, bool *paudio_only);
+
+
/**
* @}
*/
return PLAYER_ERROR_NONE;
}
+
+int legacy_player_set_audio_only(player_h player, bool audio_only)
+{
+ PLAYER_INSTANCE_CHECK(player);
+ player_s *handle = (player_s *)player;
+
+ int ret = mm_player_set_audio_only(handle->mm_handle, audio_only);
+ if (ret != MM_ERROR_NONE)
+ return __player_convert_error_code(ret, (char *)__FUNCTION__);
+ else
+ return PLAYER_ERROR_NONE;
+}
+
+int legacy_player_is_audio_only(player_h player, bool *paudio_only)
+{
+ PLAYER_INSTANCE_CHECK(player);
+ PLAYER_NULL_ARG_CHECK(paudio_only);
+ player_s *handle = (player_s *)player;
+ bool audio_only = false;
+
+ int ret = mm_player_get_audio_only(handle->mm_handle, &audio_only);
+ if (ret != MM_ERROR_NONE) {
+ return __player_convert_error_code(ret, (char *)__FUNCTION__);
+ } else {
+ *paudio_only = audio_only;
+ return PLAYER_ERROR_NONE;
+ }
+}
enable_media_packet_video_frame_decoded_cb
get_adaptive_variant_info
set_max_adaptive_variant_limit
-get_max_adaptive_variant_limit
\ No newline at end of file
+get_max_adaptive_variant_limit
+set_audio_only
+is_audio_only
\ No newline at end of file
return ret;
}
+
+int player_disp_set_audio_only(muse_module_h module)
+{
+ int ret = PLAYER_ERROR_NONE;
+ muse_player_api_e api = MUSE_PLAYER_API_SET_AUDIO_ONLY;
+ muse_player_handle_s *muse_player = NULL;
+ int audio_only = 0;
+
+ muse_player = (muse_player_handle_s *)muse_core_ipc_get_handle(module);
+ player_msg_get(audio_only, muse_core_client_get_msg(module));
+
+ ret = legacy_player_set_audio_only(muse_player->player_handle, (bool)audio_only);
+
+ player_msg_return(api, ret, module);
+
+ return ret;
+}
+
+int player_disp_is_audio_only(muse_module_h module)
+{
+ int ret = PLAYER_ERROR_NONE;
+ muse_player_api_e api = MUSE_PLAYER_API_IS_AUDIO_ONLY;
+ muse_player_handle_s *muse_player = NULL;
+ bool audio_only;
+
+ muse_player = (muse_player_handle_s *)muse_core_ipc_get_handle(module);
+
+ ret = legacy_player_is_audio_only(muse_player->player_handle, &audio_only);
+
+ player_msg_return1(api, ret, module, INT, audio_only);
+
+ return ret;
+}
Name: mmsvc-player
Summary: A Media Player module for muse server
-Version: 0.2.58
+Version: 0.2.59
Release: 0
Group: Multimedia/Libraries
License: Apache-2.0