[0.2.101] return attr value in case of idle state 17/199417/2 accepted/tizen/unified/20190214.060535 submit/tizen/20190213.031645
authorEunhae Choi <eunhae1.choi@samsung.com>
Mon, 11 Feb 2019 08:04:38 +0000 (17:04 +0900)
committerEunhae Choi <eunhae1.choi@samsung.com>
Mon, 11 Feb 2019 08:20:16 +0000 (17:20 +0900)
- attr value which is set by user via API
  will be applied to player during preparing.

Change-Id: I223c15280ee9f077f8b81478db61f9b08b999cf3

legacy/src/legacy_player.c
packaging/mmsvc-player.spec

index 53f6fc7..deff30b 100644 (file)
@@ -2698,6 +2698,16 @@ int legacy_player_get_streaming_buffering_time(player_h player, int *prebuffer_m
                return PLAYER_ERROR_INVALID_STATE;
        }
 
+       if (handle->state < PLAYER_STATE_READY) {
+               ret = mm_player_get_attribute(handle->mm_handle, NULL,
+                       MM_PLAYER_PREBUFFER_MS, prebuffer_ms, MM_PLAYER_REBUFFER_MS, rebuffer_ms, (char *)NULL);
+               if (ret != MM_ERROR_NONE)
+                       return __player_convert_error_code(ret, (char *)__FUNCTION__);
+
+               LOGD("pre: %d ms, re: %d ms", *prebuffer_ms, *rebuffer_ms);
+               return PLAYER_ERROR_NONE;
+       }
+
        ret = mm_player_get_streaming_buffering_time(handle->mm_handle, prebuffer_ms, rebuffer_ms);
        if (ret != MM_ERROR_NONE)
                return __player_convert_error_code(ret, (char *)__FUNCTION__);
index e4fe5aa..0868570 100644 (file)
@@ -1,6 +1,6 @@
 Name:       mmsvc-player
 Summary:    A Media Player module for muse server
-Version:    0.2.100
+Version:    0.2.101
 Release:    0
 Group:      Multimedia/Libraries
 License:    Apache-2.0