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

Unified Diff: media/filters/ffmpeg_audio_decoder.h

Issue 339653003: No EOS frame in {Audio|Video}Decoder::OutputCB. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase only Created 6 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/filters/fake_video_decoder_unittest.cc ('k') | media/filters/ffmpeg_audio_decoder.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/filters/ffmpeg_audio_decoder.h
diff --git a/media/filters/ffmpeg_audio_decoder.h b/media/filters/ffmpeg_audio_decoder.h
index 8dcbf92e36acce81e54b70581aa5fd17cb60b5c4..be6e4ab85f774525fa3f9b226418e56838e1a7a0 100644
--- a/media/filters/ffmpeg_audio_decoder.h
+++ b/media/filters/ffmpeg_audio_decoder.h
@@ -45,6 +45,26 @@ class MEDIA_EXPORT FFmpegAudioDecoder : public AudioDecoder {
virtual void Stop() OVERRIDE;
private:
+ // There are four states the decoder can be in:
+ //
+ // - kUninitialized: The decoder is not initialized.
+ // - kNormal: This is the normal state. The decoder is idle and ready to
+ // decode input buffers, or is decoding an input buffer.
+ // - kDecodeFinished: EOS buffer received, codec flushed and decode finished.
+ // No further Decode() call should be made.
+ // - kError: Unexpected error happened.
+ //
+ // These are the possible state transitions.
+ //
+ // kkUninitialized -> kNormal:
DaleCurtis 2014/06/17 20:48:19 Extra kk
xhwang 2014/06/17 22:43:09 Done.
+ // The decoder is successfully initialized and is ready to decode buffers.
+ // kNormal -> kDecodeFinished:
+ // When buffer->end_of_stream() is true and avcodec_decode_audio4()
+ // returns 0 data.
+ // kNormal -> kError:
+ // A decoding error occurs and decoding needs to stop.
+ // (any state) -> kNormal:
+ // Any time Reset() is called.
enum DecoderState {
kUninitialized,
kNormal,
« no previous file with comments | « media/filters/fake_video_decoder_unittest.cc ('k') | media/filters/ffmpeg_audio_decoder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698