| 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_FILTERS_OPUS_AUDIO_DECODER_H_ | 5 #ifndef MEDIA_FILTERS_OPUS_AUDIO_DECODER_H_ |
| 6 #define MEDIA_FILTERS_OPUS_AUDIO_DECODER_H_ | 6 #define MEDIA_FILTERS_OPUS_AUDIO_DECODER_H_ |
| 7 | 7 |
| 8 #include "base/callback.h" | 8 #include "base/callback.h" |
| 9 #include "base/macros.h" | 9 #include "base/macros.h" |
| 10 #include "base/time/time.h" | 10 #include "base/time/time.h" |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 | 27 |
| 28 class MEDIA_EXPORT OpusAudioDecoder : public AudioDecoder { | 28 class MEDIA_EXPORT OpusAudioDecoder : public AudioDecoder { |
| 29 public: | 29 public: |
| 30 explicit OpusAudioDecoder( | 30 explicit OpusAudioDecoder( |
| 31 const scoped_refptr<base::SingleThreadTaskRunner>& task_runner); | 31 const scoped_refptr<base::SingleThreadTaskRunner>& task_runner); |
| 32 ~OpusAudioDecoder() override; | 32 ~OpusAudioDecoder() override; |
| 33 | 33 |
| 34 // AudioDecoder implementation. | 34 // AudioDecoder implementation. |
| 35 std::string GetDisplayName() const override; | 35 std::string GetDisplayName() const override; |
| 36 void Initialize(const AudioDecoderConfig& config, | 36 void Initialize(const AudioDecoderConfig& config, |
| 37 const SetCdmReadyCB& set_cdm_ready_cb, | 37 CdmContext* cdm_context, |
| 38 const InitCB& init_cb, | 38 const InitCB& init_cb, |
| 39 const OutputCB& output_cb) override; | 39 const OutputCB& output_cb) override; |
| 40 void Decode(const scoped_refptr<DecoderBuffer>& buffer, | 40 void Decode(const scoped_refptr<DecoderBuffer>& buffer, |
| 41 const DecodeCB& decode_cb) override; | 41 const DecodeCB& decode_cb) override; |
| 42 void Reset(const base::Closure& closure) override; | 42 void Reset(const base::Closure& closure) override; |
| 43 | 43 |
| 44 private: | 44 private: |
| 45 // Reads from the demuxer stream with corresponding callback method. | 45 // Reads from the demuxer stream with corresponding callback method. |
| 46 void ReadFromDemuxerStream(); | 46 void ReadFromDemuxerStream(); |
| 47 void DecodeBuffer(const scoped_refptr<DecoderBuffer>& input, | 47 void DecodeBuffer(const scoped_refptr<DecoderBuffer>& input, |
| (...skipping 11 matching lines...) Expand all Loading... |
| 59 OutputCB output_cb_; | 59 OutputCB output_cb_; |
| 60 OpusMSDecoder* opus_decoder_; | 60 OpusMSDecoder* opus_decoder_; |
| 61 scoped_ptr<AudioDiscardHelper> discard_helper_; | 61 scoped_ptr<AudioDiscardHelper> discard_helper_; |
| 62 | 62 |
| 63 DISALLOW_IMPLICIT_CONSTRUCTORS(OpusAudioDecoder); | 63 DISALLOW_IMPLICIT_CONSTRUCTORS(OpusAudioDecoder); |
| 64 }; | 64 }; |
| 65 | 65 |
| 66 } // namespace media | 66 } // namespace media |
| 67 | 67 |
| 68 #endif // MEDIA_FILTERS_OPUS_AUDIO_DECODER_H_ | 68 #endif // MEDIA_FILTERS_OPUS_AUDIO_DECODER_H_ |
| OLD | NEW |