Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(598)

Side by Side Diff: media/filters/dummy_demuxer.cc

Issue 10829108: Cap sourceBuffered() on duration and truncate duration on EoS (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase ToT Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « media/filters/dummy_demuxer.h ('k') | media/filters/ffmpeg_demuxer.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "media/filters/dummy_demuxer.h" 5 #include "media/filters/dummy_demuxer.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 8
9 namespace media { 9 namespace media {
10 10
(...skipping 14 matching lines...) Expand all
25 25
26 const VideoDecoderConfig& DummyDemuxerStream::video_decoder_config() { 26 const VideoDecoderConfig& DummyDemuxerStream::video_decoder_config() {
27 CHECK_EQ(type_, VIDEO); 27 CHECK_EQ(type_, VIDEO);
28 return video_config_; 28 return video_config_;
29 } 29 }
30 30
31 void DummyDemuxerStream::Read(const ReadCB& read_cb) {} 31 void DummyDemuxerStream::Read(const ReadCB& read_cb) {}
32 32
33 void DummyDemuxerStream::EnableBitstreamConverter() {} 33 void DummyDemuxerStream::EnableBitstreamConverter() {}
34 34
35 Ranges<base::TimeDelta> DummyDemuxerStream::GetBufferedRanges() {
36 return Ranges<base::TimeDelta>();
37 }
38
39 DummyDemuxer::DummyDemuxer(bool has_video, bool has_audio) { 35 DummyDemuxer::DummyDemuxer(bool has_video, bool has_audio) {
40 streams_.resize(DemuxerStream::NUM_TYPES); 36 streams_.resize(DemuxerStream::NUM_TYPES);
41 if (has_audio) 37 if (has_audio)
42 streams_[DemuxerStream::AUDIO] = 38 streams_[DemuxerStream::AUDIO] =
43 new DummyDemuxerStream(DemuxerStream::AUDIO); 39 new DummyDemuxerStream(DemuxerStream::AUDIO);
44 if (has_video) 40 if (has_video)
45 streams_[DemuxerStream::VIDEO] = 41 streams_[DemuxerStream::VIDEO] =
46 new DummyDemuxerStream(DemuxerStream::VIDEO); 42 new DummyDemuxerStream(DemuxerStream::VIDEO);
47 } 43 }
48 44
(...skipping 11 matching lines...) Expand all
60 return base::TimeDelta(); 56 return base::TimeDelta();
61 } 57 }
62 58
63 int DummyDemuxer::GetBitrate() { 59 int DummyDemuxer::GetBitrate() {
64 return 0; 60 return 0;
65 } 61 }
66 62
67 DummyDemuxer::~DummyDemuxer() {} 63 DummyDemuxer::~DummyDemuxer() {}
68 64
69 } // namespace media 65 } // namespace media
OLDNEW
« no previous file with comments | « media/filters/dummy_demuxer.h ('k') | media/filters/ffmpeg_demuxer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698