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 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
70 double volume_; | 70 double volume_; |
71 | 71 |
72 // Number of bytes per audio frame. Depends on the output format and the | 72 // Number of bytes per audio frame. Depends on the output format and the |
73 // number of channels. | 73 // number of channels. |
74 int bytes_per_frame_; | 74 int bytes_per_frame_; |
75 | 75 |
76 // The sampling rate received from decoder. | 76 // The sampling rate received from decoder. |
77 int output_sampling_rate_; | 77 int output_sampling_rate_; |
78 | 78 |
79 // Frame count to sync with audio codec output. | 79 // Frame count to sync with audio codec output. |
80 int64 frame_count_; | 80 int64_t frame_count_; |
81 | 81 |
82 // Base timestamp for the |audio_timestamp_helper_|. | 82 // Base timestamp for the |audio_timestamp_helper_|. |
83 base::TimeDelta base_timestamp_; | 83 base::TimeDelta base_timestamp_; |
84 | 84 |
85 // Object to calculate the current audio timestamp for A/V sync. | 85 // Object to calculate the current audio timestamp for A/V sync. |
86 scoped_ptr<AudioTimestampHelper> audio_timestamp_helper_; | 86 scoped_ptr<AudioTimestampHelper> audio_timestamp_helper_; |
87 | 87 |
88 // Reports current playback time to the callee. | 88 // Reports current playback time to the callee. |
89 SetTimeCallback update_current_time_cb_; | 89 SetTimeCallback update_current_time_cb_; |
90 | 90 |
91 // The time limit for the next frame to avoid underrun. | 91 // The time limit for the next frame to avoid underrun. |
92 base::TimeTicks next_frame_time_limit_; | 92 base::TimeTicks next_frame_time_limit_; |
93 | 93 |
94 DISALLOW_COPY_AND_ASSIGN(MediaCodecAudioDecoder); | 94 DISALLOW_COPY_AND_ASSIGN(MediaCodecAudioDecoder); |
95 }; | 95 }; |
96 | 96 |
97 } // namespace media | 97 } // namespace media |
98 | 98 |
99 #endif // MEDIA_BASE_ANDROID_MEDIA_CODEC_DECODER_H_ | 99 #endif // MEDIA_BASE_ANDROID_MEDIA_CODEC_DECODER_H_ |
OLD | NEW |