From 737d79586e0c95b49aa3f18fefce7066a5b68826 Mon Sep 17 00:00:00 2001 From: Eunhye Choi Date: Wed, 10 Apr 2019 16:26:24 +0900 Subject: [PATCH] [ACR-1370][2] Apply the changed API naming - add 'audio' prefix into API naming not to be confused with the pitch value of 360 video Change-Id: Ib27ba5706d25046e451d4dd4902b19d191b6938a --- include/player.h | 34 +++++++++++++++++----------------- src/player.c | 8 ++++---- test/player_test.c | 8 ++++---- 3 files changed, 25 insertions(+), 25 deletions(-) diff --git a/include/player.h b/include/player.h index f0d6e6d..dc3850a 100644 --- a/include/player.h +++ b/include/player.h @@ -2350,11 +2350,11 @@ int player_get_video_roi_area(player_h player, double *x_scale, double *y_scale, * @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter * @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation * @pre The player state must be #PLAYER_STATE_IDLE. - * @see player_pitch_is_enabled() - * @see player_pitch_set_value() - * @see player_pitch_get_value() + * @see player_audio_pitch_is_enabled() + * @see player_audio_pitch_set_value() + * @see player_audio_pitch_get_value() */ -int player_pitch_set_enabled(player_h player, bool enabled); +int player_audio_pitch_set_enabled(player_h player, bool enabled); /** * @brief Gets the audio pitch control status. @@ -2367,11 +2367,11 @@ int player_pitch_set_enabled(player_h player, bool enabled); * @retval #PLAYER_ERROR_NONE Successful * @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter * @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation - * @see player_pitch_set_enabled() - * @see player_pitch_set_value() - * @see player_pitch_get_value() + * @see player_audio_pitch_set_enabled() + * @see player_audio_pitch_set_value() + * @see player_audio_pitch_get_value() */ -int player_pitch_is_enabled(player_h player, bool *enabled); +int player_audio_pitch_is_enabled(player_h player, bool *enabled); /** * @brief Sets the audio pitch value. @@ -2385,12 +2385,12 @@ int player_pitch_is_enabled(player_h player, bool *enabled); * @retval #PLAYER_ERROR_NONE Successful * @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter * @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation - * @pre The pitch control must be enabled by calling player_pitch_set_enabled() function. - * @see player_pitch_set_enabled() - * @see player_pitch_is_enabled() - * @see player_pitch_get_value() + * @pre The pitch control must be enabled by calling player_audio_pitch_set_enabled() function. + * @see player_audio_pitch_set_enabled() + * @see player_audio_pitch_is_enabled() + * @see player_audio_pitch_get_value() */ -int player_pitch_set_value(player_h player, float value); +int player_audio_pitch_set_value(player_h player, float value); /** * @brief Gets the audio pitch value. @@ -2404,11 +2404,11 @@ int player_pitch_set_value(player_h player, float value); * @retval #PLAYER_ERROR_NONE Successful * @retval #PLAYER_ERROR_INVALID_PARAMETER Invalid parameter * @retval #PLAYER_ERROR_INVALID_OPERATION Invalid operation - * @see player_pitch_set_enabled() - * @see player_pitch_is_enabled() - * @see player_pitch_set_value() + * @see player_audio_pitch_set_enabled() + * @see player_audio_pitch_is_enabled() + * @see player_audio_pitch_set_value() */ -int player_pitch_get_value(player_h player, float *value); +int player_audio_pitch_get_value(player_h player, float *value); /** * @} diff --git a/src/player.c b/src/player.c index d642b61..c149be1 100644 --- a/src/player.c +++ b/src/player.c @@ -5140,7 +5140,7 @@ int player_is_replaygain_enabled(player_h player, bool *enabled) return ret; } -int player_pitch_set_enabled(player_h player, bool enabled) +int player_audio_pitch_set_enabled(player_h player, bool enabled) { PLAYER_INSTANCE_CHECK(player); int ret = PLAYER_ERROR_NONE; @@ -5156,7 +5156,7 @@ int player_pitch_set_enabled(player_h player, bool enabled) return ret; } -int player_pitch_is_enabled(player_h player, bool *enabled) +int player_audio_pitch_is_enabled(player_h player, bool *enabled) { PLAYER_INSTANCE_CHECK(player); PLAYER_NULL_ARG_CHECK(enabled); @@ -5178,7 +5178,7 @@ int player_pitch_is_enabled(player_h player, bool *enabled) return ret; } -int player_pitch_set_value(player_h player, float value) +int player_audio_pitch_set_value(player_h player, float value) { PLAYER_INSTANCE_CHECK(player); PLAYER_CHECK_CONDITION(value >= 0.5 && value <= 2.0, PLAYER_ERROR_INVALID_PARAMETER, "PLAYER_ERROR_INVALID_PARAMETER"); @@ -5197,7 +5197,7 @@ int player_pitch_set_value(player_h player, float value) return ret; } -int player_pitch_get_value(player_h player, float *value) +int player_audio_pitch_get_value(player_h player, float *value) { PLAYER_INSTANCE_CHECK(player); PLAYER_NULL_ARG_CHECK(value); diff --git a/test/player_test.c b/test/player_test.c index b47048b..d949b4f 100644 --- a/test/player_test.c +++ b/test/player_test.c @@ -2065,20 +2065,20 @@ static void set_audio_offload_enabled(bool enabled) static void pitch_set_enabled(bool enabled) { bool is_enabled = false; - player_pitch_is_enabled(g_player[0], &is_enabled); + player_audio_pitch_is_enabled(g_player[0], &is_enabled); g_print("pitch enabled %d -> %d \n", is_enabled, enabled); - if (player_pitch_set_enabled(g_player[0], enabled) != PLAYER_ERROR_NONE) + if (player_audio_pitch_set_enabled(g_player[0], enabled) != PLAYER_ERROR_NONE) g_print("failed to pitch_set_enabled\n"); } static void pitch_set_value(float level) { float curr = 0.0; - player_pitch_get_value(g_player[0], &curr); + player_audio_pitch_get_value(g_player[0], &curr); g_print("pitch level %1.3f -> %1.3f \n", curr, level); - if (player_pitch_set_value(g_player[0], level) != PLAYER_ERROR_NONE) + if (player_audio_pitch_set_value(g_player[0], level) != PLAYER_ERROR_NONE) g_print("failed to set pitch value\n"); } -- 2.7.4