| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_DECODER_STREAM_H_ | 5 #ifndef MEDIA_FILTERS_DECODER_STREAM_H_ |
| 6 #define MEDIA_FILTERS_DECODER_STREAM_H_ | 6 #define MEDIA_FILTERS_DECODER_STREAM_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/callback.h" | 9 #include "base/callback.h" |
| 10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
| (...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 114 } | 114 } |
| 115 | 115 |
| 116 private: | 116 private: |
| 117 enum State { | 117 enum State { |
| 118 STATE_UNINITIALIZED, | 118 STATE_UNINITIALIZED, |
| 119 STATE_INITIALIZING, | 119 STATE_INITIALIZING, |
| 120 STATE_NORMAL, // Includes idle, pending decoder decode/reset/stop. | 120 STATE_NORMAL, // Includes idle, pending decoder decode/reset/stop. |
| 121 STATE_FLUSHING_DECODER, | 121 STATE_FLUSHING_DECODER, |
| 122 STATE_PENDING_DEMUXER_READ, | 122 STATE_PENDING_DEMUXER_READ, |
| 123 STATE_REINITIALIZING_DECODER, | 123 STATE_REINITIALIZING_DECODER, |
| 124 STATE_END_OF_STREAM, // End of stream reached; returns EOS on all reads. |
| 124 STATE_STOPPED, | 125 STATE_STOPPED, |
| 125 STATE_ERROR | 126 STATE_ERROR |
| 126 }; | 127 }; |
| 127 | 128 |
| 128 // Called when |decoder_selector| selected the |selected_decoder|. | 129 // Called when |decoder_selector| selected the |selected_decoder|. |
| 129 // |decrypting_demuxer_stream| was also populated if a DecryptingDemuxerStream | 130 // |decrypting_demuxer_stream| was also populated if a DecryptingDemuxerStream |
| 130 // is created to help decrypt the encrypted stream. | 131 // is created to help decrypt the encrypted stream. |
| 131 void OnDecoderSelected( | 132 void OnDecoderSelected( |
| 132 scoped_ptr<Decoder> selected_decoder, | 133 scoped_ptr<Decoder> selected_decoder, |
| 133 scoped_ptr<DecryptingDemuxerStream> decrypting_demuxer_stream); | 134 scoped_ptr<DecryptingDemuxerStream> decrypting_demuxer_stream); |
| (...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 213 | 214 |
| 214 template <> | 215 template <> |
| 215 int DecoderStream<DemuxerStream::AUDIO>::GetMaxDecodeRequests() const; | 216 int DecoderStream<DemuxerStream::AUDIO>::GetMaxDecodeRequests() const; |
| 216 | 217 |
| 217 typedef DecoderStream<DemuxerStream::VIDEO> VideoFrameStream; | 218 typedef DecoderStream<DemuxerStream::VIDEO> VideoFrameStream; |
| 218 typedef DecoderStream<DemuxerStream::AUDIO> AudioBufferStream; | 219 typedef DecoderStream<DemuxerStream::AUDIO> AudioBufferStream; |
| 219 | 220 |
| 220 } // namespace media | 221 } // namespace media |
| 221 | 222 |
| 222 #endif // MEDIA_FILTERS_DECODER_STREAM_H_ | 223 #endif // MEDIA_FILTERS_DECODER_STREAM_H_ |
| OLD | NEW |