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_BASE_AUDIO_DECODER_H_ | 5 #ifndef MEDIA_BASE_AUDIO_DECODER_H_ |
6 #define MEDIA_BASE_AUDIO_DECODER_H_ | 6 #define MEDIA_BASE_AUDIO_DECODER_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/callback.h" | 10 #include "base/callback.h" |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
78 // If |buffer| is an EOS buffer then the decoder must be flushed, i.e. | 78 // If |buffer| is an EOS buffer then the decoder must be flushed, i.e. |
79 // |output_cb| must be called for each frame pending in the queue and | 79 // |output_cb| must be called for each frame pending in the queue and |
80 // |decode_cb| must be called after that. | 80 // |decode_cb| must be called after that. |
81 virtual void Decode(const scoped_refptr<DecoderBuffer>& buffer, | 81 virtual void Decode(const scoped_refptr<DecoderBuffer>& buffer, |
82 const DecodeCB& decode_cb) = 0; | 82 const DecodeCB& decode_cb) = 0; |
83 | 83 |
84 // Resets decoder state. All pending Decode() requests will be finished or | 84 // Resets decoder state. All pending Decode() requests will be finished or |
85 // aborted before |closure| is called. | 85 // aborted before |closure| is called. |
86 virtual void Reset(const base::Closure& closure) = 0; | 86 virtual void Reset(const base::Closure& closure) = 0; |
87 | 87 |
88 // Returns true if the decoder needs bitstream conversion before decoding. | |
89 virtual bool NeedsBitstreamConversion() const; | |
DaleCurtis
2016/02/18 04:04:37
Hmm, interface used to be pure virtual up to this
| |
90 | |
88 private: | 91 private: |
89 DISALLOW_COPY_AND_ASSIGN(AudioDecoder); | 92 DISALLOW_COPY_AND_ASSIGN(AudioDecoder); |
90 }; | 93 }; |
91 | 94 |
92 } // namespace media | 95 } // namespace media |
93 | 96 |
94 #endif // MEDIA_BASE_AUDIO_DECODER_H_ | 97 #endif // MEDIA_BASE_AUDIO_DECODER_H_ |
OLD | NEW |