Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1040)

Unified Diff: media/base/audio_buffer.cc

Issue 1838203003: [TO M50] Enable implicit signalling for HE AAC v1 & v2 in ADTS. (Closed) Base URL: https://chromium.googlesource.com/a/chromium/src.git@2661
Patch Set: Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/base/audio_buffer.h ('k') | media/filters/ffmpeg_audio_decoder.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/base/audio_buffer.cc
diff --git a/media/base/audio_buffer.cc b/media/base/audio_buffer.cc
index 1ea2363e726b14609721bd436f0bb81906a40277..9370ee891b0ec16519cd0b06ad08135847ad14f3 100644
--- a/media/base/audio_buffer.cc
+++ b/media/base/audio_buffer.cc
@@ -208,6 +208,12 @@ inline int16_t ConvertSample<float, int16_t>(float sample) {
: sample * std::numeric_limits<int16_t>::max()));
}
+void AudioBuffer::AdjustSampleRate(int sample_rate) {
+ DCHECK(!end_of_stream_);
+ sample_rate_ = sample_rate;
+ duration_ = CalculateDuration(adjusted_frame_count_, sample_rate_);
+}
+
void AudioBuffer::ReadFrames(int frames_to_copy,
int source_frame_offset,
int dest_frame_offset,
« no previous file with comments | « media/base/audio_buffer.h ('k') | media/filters/ffmpeg_audio_decoder.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698