OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_UTIL_H_ | 5 #ifndef CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_UTIL_H_ |
6 #define CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_UTIL_H_ | 6 #define CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_UTIL_H_ |
7 | 7 |
8 #include "base/time/time.h" | 8 #include "base/time/time.h" |
9 #include "media/base/pipeline_status.h" | 9 #include "media/base/pipeline_status.h" |
10 #include "media/base/ranges.h" | 10 #include "media/base/ranges.h" |
| 11 #include "third_party/WebKit/public/platform/WebMediaPlayer.h" |
11 #include "third_party/WebKit/public/platform/WebTimeRange.h" | 12 #include "third_party/WebKit/public/platform/WebTimeRange.h" |
12 #include "third_party/WebKit/public/web/WebMediaPlayer.h" | |
13 | 13 |
14 namespace content { | 14 namespace content { |
15 | 15 |
16 // Platform independent method for converting and rounding floating point | 16 // Platform independent method for converting and rounding floating point |
17 // seconds to an int64 timestamp. | 17 // seconds to an int64 timestamp. |
18 // | 18 // |
19 // Refer to https://bugs.webkit.org/show_bug.cgi?id=52697 for details. | 19 // Refer to https://bugs.webkit.org/show_bug.cgi?id=52697 for details. |
20 base::TimeDelta ConvertSecondsToTimestamp(double seconds); | 20 base::TimeDelta ConvertSecondsToTimestamp(double seconds); |
21 | 21 |
22 blink::WebTimeRanges ConvertToWebTimeRanges( | 22 blink::WebTimeRanges ConvertToWebTimeRanges( |
23 const media::Ranges<base::TimeDelta>& ranges); | 23 const media::Ranges<base::TimeDelta>& ranges); |
24 | 24 |
25 blink::WebMediaPlayer::NetworkState PipelineErrorToNetworkState( | 25 blink::WebMediaPlayer::NetworkState PipelineErrorToNetworkState( |
26 media::PipelineStatus error); | 26 media::PipelineStatus error); |
27 | 27 |
28 } // namespace content | 28 } // namespace content |
29 | 29 |
30 #endif // CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_UTIL_H_ | 30 #endif // CONTENT_RENDERER_MEDIA_WEBMEDIAPLAYER_UTIL_H_ |
OLD | NEW |