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

Side by Side Diff: content/common/media/audio_param_traits.cc

Issue 11198018: Move ChannelLayout into media namespace. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Fixes. Created 8 years, 2 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 unified diff | Download patch
« no previous file with comments | « content/browser/speech/speech_recognizer.cc ('k') | content/common/view_messages.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #include "content/common/media/audio_param_traits.h" 5 #include "content/common/media/audio_param_traits.h"
6 6
7 #include "base/stringprintf.h" 7 #include "base/stringprintf.h"
8 #include "media/audio/audio_parameters.h" 8 #include "media/audio/audio_parameters.h"
9 9
10 using media::AudioParameters; 10 using media::AudioParameters;
11 using media::ChannelLayout;
11 12
12 namespace IPC { 13 namespace IPC {
13 14
14 void ParamTraits<AudioParameters>::Write(Message* m, 15 void ParamTraits<AudioParameters>::Write(Message* m,
15 const AudioParameters& p) { 16 const AudioParameters& p) {
16 m->WriteInt(static_cast<int>(p.format())); 17 m->WriteInt(static_cast<int>(p.format()));
17 m->WriteInt(static_cast<int>(p.channel_layout())); 18 m->WriteInt(static_cast<int>(p.channel_layout()));
18 m->WriteInt(p.sample_rate()); 19 m->WriteInt(p.sample_rate());
19 m->WriteInt(p.bits_per_sample()); 20 m->WriteInt(p.bits_per_sample());
20 m->WriteInt(p.frames_per_buffer()); 21 m->WriteInt(p.frames_per_buffer());
(...skipping 18 matching lines...) Expand all
39 sample_rate, bits_per_sample, frames_per_buffer); 40 sample_rate, bits_per_sample, frames_per_buffer);
40 return true; 41 return true;
41 } 42 }
42 43
43 void ParamTraits<AudioParameters>::Log(const AudioParameters& p, 44 void ParamTraits<AudioParameters>::Log(const AudioParameters& p,
44 std::string* l) { 45 std::string* l) {
45 l->append(base::StringPrintf("<AudioParameters>")); 46 l->append(base::StringPrintf("<AudioParameters>"));
46 } 47 }
47 48
48 } 49 }
OLDNEW
« no previous file with comments | « content/browser/speech/speech_recognizer.cc ('k') | content/common/view_messages.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698