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 #include "content/renderer/media/android/media_source_delegate.h" | 5 #include "content/renderer/media/android/media_source_delegate.h" |
6 | 6 |
7 #include <limits> | 7 #include <limits> |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
183 media_weak_factory_.GetWeakPtr()), | 183 media_weak_factory_.GetWeakPtr()), |
184 false); | 184 false); |
185 } | 185 } |
186 | 186 |
187 const blink::WebTimeRanges& MediaSourceDelegate::Buffered() { | 187 const blink::WebTimeRanges& MediaSourceDelegate::Buffered() { |
188 buffered_web_time_ranges_ = | 188 buffered_web_time_ranges_ = |
189 ConvertToWebTimeRanges(buffered_time_ranges_); | 189 ConvertToWebTimeRanges(buffered_time_ranges_); |
190 return buffered_web_time_ranges_; | 190 return buffered_web_time_ranges_; |
191 } | 191 } |
192 | 192 |
| 193 blink::WebTimeRanges MediaSourceDelegate::Buffered() const { |
| 194 return ConvertToWebTimeRanges(buffered_time_ranges_); |
| 195 } |
| 196 |
193 size_t MediaSourceDelegate::DecodedFrameCount() const { | 197 size_t MediaSourceDelegate::DecodedFrameCount() const { |
194 return statistics_.video_frames_decoded; | 198 return statistics_.video_frames_decoded; |
195 } | 199 } |
196 | 200 |
197 size_t MediaSourceDelegate::DroppedFrameCount() const { | 201 size_t MediaSourceDelegate::DroppedFrameCount() const { |
198 return statistics_.video_frames_dropped; | 202 return statistics_.video_frames_dropped; |
199 } | 203 } |
200 | 204 |
201 size_t MediaSourceDelegate::AudioDecodedByteCount() const { | 205 size_t MediaSourceDelegate::AudioDecodedByteCount() const { |
202 return statistics_.audio_bytes_decoded; | 206 return statistics_.audio_bytes_decoded; |
(...skipping 563 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
766 configs->video_size = config.natural_size(); | 770 configs->video_size = config.natural_size(); |
767 configs->is_video_encrypted = config.is_encrypted(); | 771 configs->is_video_encrypted = config.is_encrypted(); |
768 configs->video_extra_data = std::vector<uint8>( | 772 configs->video_extra_data = std::vector<uint8>( |
769 config.extra_data(), config.extra_data() + config.extra_data_size()); | 773 config.extra_data(), config.extra_data() + config.extra_data_size()); |
770 return true; | 774 return true; |
771 } | 775 } |
772 return false; | 776 return false; |
773 } | 777 } |
774 | 778 |
775 } // namespace content | 779 } // namespace content |
OLD | NEW |