OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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_ANDROID_MEDIA_CODEC_AUDIO_DECODER_H_ | 5 #ifndef MEDIA_BASE_ANDROID_MEDIA_CODEC_AUDIO_DECODER_H_ |
6 #define MEDIA_BASE_ANDROID_MEDIA_CODEC_AUDIO_DECODER_H_ | 6 #define MEDIA_BASE_ANDROID_MEDIA_CODEC_AUDIO_DECODER_H_ |
7 | 7 |
8 #include "media/base/android/media_codec_decoder.h" | 8 #include "media/base/android/media_codec_decoder.h" |
9 | 9 |
10 namespace media { | 10 namespace media { |
(...skipping 26 matching lines...) Expand all Loading... |
37 | 37 |
38 // Sets the base timestamp for |audio_timestamp_helper_|. | 38 // Sets the base timestamp for |audio_timestamp_helper_|. |
39 void SetBaseTimestamp(base::TimeDelta base_timestamp); | 39 void SetBaseTimestamp(base::TimeDelta base_timestamp); |
40 | 40 |
41 protected: | 41 protected: |
42 bool IsCodecReconfigureNeeded(const DemuxerConfigs& curr, | 42 bool IsCodecReconfigureNeeded(const DemuxerConfigs& curr, |
43 const DemuxerConfigs& next) const override; | 43 const DemuxerConfigs& next) const override; |
44 ConfigStatus ConfigureInternal() override; | 44 ConfigStatus ConfigureInternal() override; |
45 void OnOutputFormatChanged() override; | 45 void OnOutputFormatChanged() override; |
46 void Render(int buffer_index, | 46 void Render(int buffer_index, |
| 47 size_t offset, |
47 size_t size, | 48 size_t size, |
48 bool render_output, | 49 bool render_output, |
49 base::TimeDelta pts, | 50 base::TimeDelta pts, |
50 bool eos_encountered) override; | 51 bool eos_encountered) override; |
51 | 52 |
52 private: | 53 private: |
53 // A helper method to set the volume. | 54 // A helper method to set the volume. |
54 void SetVolumeInternal(); | 55 void SetVolumeInternal(); |
55 | 56 |
56 // Recreates |audio_timestamp_helper_|, called when sampling rate is changed. | 57 // Recreates |audio_timestamp_helper_|, called when sampling rate is changed. |
(...skipping 25 matching lines...) Expand all Loading... |
82 | 83 |
83 // Reports current playback time to the callee. | 84 // Reports current playback time to the callee. |
84 SetTimeCallback update_current_time_cb_; | 85 SetTimeCallback update_current_time_cb_; |
85 | 86 |
86 DISALLOW_COPY_AND_ASSIGN(MediaCodecAudioDecoder); | 87 DISALLOW_COPY_AND_ASSIGN(MediaCodecAudioDecoder); |
87 }; | 88 }; |
88 | 89 |
89 } // namespace media | 90 } // namespace media |
90 | 91 |
91 #endif // MEDIA_BASE_ANDROID_MEDIA_CODEC_DECODER_H_ | 92 #endif // MEDIA_BASE_ANDROID_MEDIA_CODEC_DECODER_H_ |
OLD | NEW |