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

Side by Side Diff: content/renderer/media/webrtc/webrtc_audio_sink_adapter.cc

Issue 1547073003: Switch to standard integer types in content/renderer/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 12 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "base/logging.h" 5 #include "base/logging.h"
6 #include "content/renderer/media/webrtc/webrtc_audio_sink_adapter.h" 6 #include "content/renderer/media/webrtc/webrtc_audio_sink_adapter.h"
7 #include "media/base/audio_bus.h" 7 #include "media/base/audio_bus.h"
8 #include "third_party/libjingle/source/talk/app/webrtc/mediastreaminterface.h" 8 #include "third_party/libjingle/source/talk/app/webrtc/mediastreaminterface.h"
9 9
10 namespace content { 10 namespace content {
(...skipping 27 matching lines...) Expand all
38 audio_bus.channels(), 38 audio_bus.channels(),
39 audio_bus.frames()); 39 audio_bus.frames());
40 } 40 }
41 41
42 void WebRtcAudioSinkAdapter::OnSetFormat( 42 void WebRtcAudioSinkAdapter::OnSetFormat(
43 const media::AudioParameters& params) { 43 const media::AudioParameters& params) {
44 DCHECK(params.IsValid()); 44 DCHECK(params.IsValid());
45 params_ = params; 45 params_ = params;
46 const int num_pcm16_data_elements = 46 const int num_pcm16_data_elements =
47 params_.frames_per_buffer() * params_.channels(); 47 params_.frames_per_buffer() * params_.channels();
48 interleaved_data_.reset(new int16[num_pcm16_data_elements]); 48 interleaved_data_.reset(new int16_t[num_pcm16_data_elements]);
49 } 49 }
50 50
51 } // namespace content 51 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698