OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "webkit/media/webmediaplayer_proxy.h" | 5 #include "webkit/media/webmediaplayer_proxy.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "base/message_loop_proxy.h" | 9 #include "base/message_loop_proxy.h" |
10 #include "media/base/pipeline_status.h" | 10 #include "media/base/pipeline_status.h" |
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
189 chunk_demuxer_->StartWaitingForSeek(); | 189 chunk_demuxer_->StartWaitingForSeek(); |
190 } | 190 } |
191 | 191 |
192 media::ChunkDemuxer::Status WebMediaPlayerProxy::DemuxerAddId( | 192 media::ChunkDemuxer::Status WebMediaPlayerProxy::DemuxerAddId( |
193 const std::string& id, | 193 const std::string& id, |
194 const std::string& type, | 194 const std::string& type, |
195 std::vector<std::string>& codecs) { | 195 std::vector<std::string>& codecs) { |
196 return chunk_demuxer_->AddId(id, type, codecs); | 196 return chunk_demuxer_->AddId(id, type, codecs); |
197 } | 197 } |
198 | 198 |
| 199 bool WebMediaPlayerProxy::DemuxerSetTimestampOffset( |
| 200 const std::string& id, double offset) { |
| 201 return chunk_demuxer_->SetTimestampOffset(id, offset); |
| 202 } |
| 203 |
199 void WebMediaPlayerProxy::DemuxerRemoveId(const std::string& id) { | 204 void WebMediaPlayerProxy::DemuxerRemoveId(const std::string& id) { |
200 chunk_demuxer_->RemoveId(id); | 205 chunk_demuxer_->RemoveId(id); |
201 } | 206 } |
202 | 207 |
203 media::Ranges<base::TimeDelta> WebMediaPlayerProxy::DemuxerBufferedRange( | 208 media::Ranges<base::TimeDelta> WebMediaPlayerProxy::DemuxerBufferedRange( |
204 const std::string& id) { | 209 const std::string& id) { |
205 return chunk_demuxer_->GetBufferedRanges(id); | 210 return chunk_demuxer_->GetBufferedRanges(id); |
206 } | 211 } |
207 | 212 |
208 bool WebMediaPlayerProxy::DemuxerAppend(const std::string& id, | 213 bool WebMediaPlayerProxy::DemuxerAppend(const std::string& id, |
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
302 const std::string& session_id, | 307 const std::string& session_id, |
303 scoped_array<uint8> init_data, | 308 scoped_array<uint8> init_data, |
304 int init_data_size) { | 309 int init_data_size) { |
305 DCHECK(render_loop_->BelongsToCurrentThread()); | 310 DCHECK(render_loop_->BelongsToCurrentThread()); |
306 if (webmediaplayer_) | 311 if (webmediaplayer_) |
307 webmediaplayer_->OnNeedKey(key_system, session_id, | 312 webmediaplayer_->OnNeedKey(key_system, session_id, |
308 init_data.Pass(), init_data_size); | 313 init_data.Pass(), init_data_size); |
309 } | 314 } |
310 | 315 |
311 } // namespace webkit_media | 316 } // namespace webkit_media |
OLD | NEW |