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

Unified Diff: media/audio/audio_util.h

Issue 7533020: Move SwizzleCoreAudioLayout5_1() closer to where it's called. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src
Patch Set: Created 9 years, 5 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 | « no previous file | media/audio/mac/audio_low_latency_output_mac.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/audio/audio_util.h
diff --git a/media/audio/audio_util.h b/media/audio/audio_util.h
index 15a0935bd7a642ee82f326a283355eaf5083e741..c74874d22dd3ee1de76f42b8de89b631969ba428 100644
--- a/media/audio/audio_util.h
+++ b/media/audio/audio_util.h
@@ -74,23 +74,6 @@ void InterleaveFloatToInt16(const std::vector<float*>& source,
int16* destination,
size_t number_of_frames);
-// Reorder PCM from AAC layout to Core Audio 5.1 layout.
-// TODO(fbarchard): Switch layout when ffmpeg is updated.
-template<class Format>
-void SwizzleCoreAudioLayout5_1(Format* b, uint32 filled) {
- static const int kNumSurroundChannels = 6;
- Format aac[kNumSurroundChannels];
- for (uint32 i = 0; i < filled; i += sizeof(aac), b += kNumSurroundChannels) {
- memcpy(aac, b, sizeof(aac));
- b[0] = aac[1]; // L
- b[1] = aac[2]; // R
- b[2] = aac[0]; // C
- b[3] = aac[5]; // LFE
- b[4] = aac[3]; // Ls
- b[5] = aac[4]; // Rs
- }
-}
-
// Returns the default audio hardware sample-rate.
double GetAudioHardwareSampleRate();
« no previous file with comments | « no previous file | media/audio/mac/audio_low_latency_output_mac.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698