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

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

Issue 8989041: Revert 115214 (caused media_unittests failure in FFmpegGlueTest, (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years 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/base/byte_queue.cc ('k') | media/filters/chunk_demuxer_unittest.cc » ('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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 // Implements a Demuxer that can switch among different data sources mid-stream. 5 // Implements a Demuxer that can switch among different data sources mid-stream.
6 // Uses FFmpegDemuxer under the covers, so see the caveats at the top of 6 // Uses FFmpegDemuxer under the covers, so see the caveats at the top of
7 // ffmpeg_demuxer.h. 7 // ffmpeg_demuxer.h.
8 8
9 #include "media/filters/chunk_demuxer.h" 9 #include "media/filters/chunk_demuxer.h"
10 10
(...skipping 392 matching lines...) Expand 10 before | Expand all | Expand 10 after
403 403
404 if (state_ == SHUTDOWN) 404 if (state_ == SHUTDOWN)
405 return; 405 return;
406 406
407 if (audio_.get()) 407 if (audio_.get())
408 audio_->Flush(); 408 audio_->Flush();
409 409
410 if (video_.get()) 410 if (video_.get())
411 video_->Flush(); 411 video_->Flush();
412 412
413 byte_queue_.Reset();
414 cluster_parser_->Reset();
415
416 seek_waits_for_data_ = true; 413 seek_waits_for_data_ = true;
417 ChangeState_Locked(INITIALIZED); 414 ChangeState_Locked(INITIALIZED);
418 } 415 }
419 416
420 bool ChunkDemuxer::AppendData(const uint8* data, size_t length) { 417 bool ChunkDemuxer::AppendData(const uint8* data, size_t length) {
421 VLOG(1) << "AppendData(" << length << ")"; 418 VLOG(1) << "AppendData(" << length << ")";
422 419
423 if (!data || length == 0u) 420 if (!data || length == 0u)
424 return false; 421 return false;
425 422
(...skipping 388 matching lines...) Expand 10 before | Expand all | Expand 10 after
814 base::AutoUnlock auto_unlock(lock_); 811 base::AutoUnlock auto_unlock(lock_);
815 if (cb.is_null()) { 812 if (cb.is_null()) {
816 host()->OnDemuxerError(error); 813 host()->OnDemuxerError(error);
817 return; 814 return;
818 } 815 }
819 cb.Run(error); 816 cb.Run(error);
820 } 817 }
821 } 818 }
822 819
823 } // namespace media 820 } // namespace media
OLDNEW
« no previous file with comments | « media/base/byte_queue.cc ('k') | media/filters/chunk_demuxer_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698