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 #ifndef MEDIA_FILTERS_CHUNK_DEMUXER_H_ | 5 #ifndef MEDIA_FILTERS_CHUNK_DEMUXER_H_ |
6 #define MEDIA_FILTERS_CHUNK_DEMUXER_H_ | 6 #define MEDIA_FILTERS_CHUNK_DEMUXER_H_ |
7 | 7 |
8 #include <deque> | 8 #include <deque> |
9 #include <map> | 9 #include <map> |
10 #include <string> | 10 #include <string> |
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
150 // |enable_text| Process inband text tracks in the normal way when true, | 150 // |enable_text| Process inband text tracks in the normal way when true, |
151 // otherwise ignore them. | 151 // otherwise ignore them. |
152 // |log_cb| Run when parsing error messages need to be logged to the error | 152 // |log_cb| Run when parsing error messages need to be logged to the error |
153 // console. | 153 // console. |
154 // |splice_frames_enabled| Indicates that it's okay to generate splice frames | 154 // |splice_frames_enabled| Indicates that it's okay to generate splice frames |
155 // per the MSE specification. Renderers must understand DecoderBuffer's | 155 // per the MSE specification. Renderers must understand DecoderBuffer's |
156 // splice_timestamp() field. | 156 // splice_timestamp() field. |
157 ChunkDemuxer(const base::Closure& open_cb, | 157 ChunkDemuxer(const base::Closure& open_cb, |
158 const NeedKeyCB& need_key_cb, | 158 const NeedKeyCB& need_key_cb, |
159 const LogCB& log_cb, | 159 const LogCB& log_cb, |
| 160 const scoped_refptr<MediaLog>& media_log, |
160 bool splice_frames_enabled); | 161 bool splice_frames_enabled); |
161 ~ChunkDemuxer() override; | 162 ~ChunkDemuxer() override; |
162 | 163 |
163 // Demuxer implementation. | 164 // Demuxer implementation. |
164 void Initialize(DemuxerHost* host, | 165 void Initialize(DemuxerHost* host, |
165 const PipelineStatusCB& cb, | 166 const PipelineStatusCB& cb, |
166 bool enable_text_tracks) override; | 167 bool enable_text_tracks) override; |
167 void Stop() override; | 168 void Stop() override; |
168 void Seek(base::TimeDelta time, const PipelineStatusCB& cb) override; | 169 void Seek(base::TimeDelta time, const PipelineStatusCB& cb) override; |
169 base::Time GetTimelineOffset() const override; | 170 base::Time GetTimelineOffset() const override; |
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
354 State state_; | 355 State state_; |
355 bool cancel_next_seek_; | 356 bool cancel_next_seek_; |
356 | 357 |
357 DemuxerHost* host_; | 358 DemuxerHost* host_; |
358 base::Closure open_cb_; | 359 base::Closure open_cb_; |
359 NeedKeyCB need_key_cb_; | 360 NeedKeyCB need_key_cb_; |
360 bool enable_text_; | 361 bool enable_text_; |
361 // Callback used to report error strings that can help the web developer | 362 // Callback used to report error strings that can help the web developer |
362 // figure out what is wrong with the content. | 363 // figure out what is wrong with the content. |
363 LogCB log_cb_; | 364 LogCB log_cb_; |
| 365 scoped_refptr<MediaLog> media_log_; |
364 | 366 |
365 PipelineStatusCB init_cb_; | 367 PipelineStatusCB init_cb_; |
366 // Callback to execute upon seek completion. | 368 // Callback to execute upon seek completion. |
367 // TODO(wolenetz/acolwell): Protect against possible double-locking by first | 369 // TODO(wolenetz/acolwell): Protect against possible double-locking by first |
368 // releasing |lock_| before executing this callback. See | 370 // releasing |lock_| before executing this callback. See |
369 // http://crbug.com/308226 | 371 // http://crbug.com/308226 |
370 PipelineStatusCB seek_cb_; | 372 PipelineStatusCB seek_cb_; |
371 | 373 |
372 scoped_ptr<ChunkDemuxerStream> audio_; | 374 scoped_ptr<ChunkDemuxerStream> audio_; |
373 scoped_ptr<ChunkDemuxerStream> video_; | 375 scoped_ptr<ChunkDemuxerStream> video_; |
(...skipping 21 matching lines...) Expand all Loading... |
395 | 397 |
396 // Indicates that splice frame generation is enabled. | 398 // Indicates that splice frame generation is enabled. |
397 const bool splice_frames_enabled_; | 399 const bool splice_frames_enabled_; |
398 | 400 |
399 DISALLOW_COPY_AND_ASSIGN(ChunkDemuxer); | 401 DISALLOW_COPY_AND_ASSIGN(ChunkDemuxer); |
400 }; | 402 }; |
401 | 403 |
402 } // namespace media | 404 } // namespace media |
403 | 405 |
404 #endif // MEDIA_FILTERS_CHUNK_DEMUXER_H_ | 406 #endif // MEDIA_FILTERS_CHUNK_DEMUXER_H_ |
OLD | NEW |