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

Side by Side Diff: content/renderer/renderer_blink_platform_impl.cc

Issue 2469023002: Support floating-point audio output for Linux (Closed)
Patch Set: Created 4 years, 1 month 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 | « no previous file | media/audio/pulse/pulse_output.cc » ('j') | media/audio/pulse/pulse_output.cc » ('J')
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/renderer/renderer_blink_platform_impl.h" 5 #include "content/renderer/renderer_blink_platform_impl.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
(...skipping 730 matching lines...) Expand 10 before | Expand all | Expand 10 after
741 base::StringPiece16(input_device_id)), &session_id)) { 741 base::StringPiece16(input_device_id)), &session_id)) {
742 if (input_channels > 0) 742 if (input_channels > 0)
743 DLOG(WARNING) << "createAudioDevice(): request for audio input ignored"; 743 DLOG(WARNING) << "createAudioDevice(): request for audio input ignored";
744 744
745 input_channels = 0; 745 input_channels = 0;
746 } 746 }
747 747
748 // For CHANNEL_LAYOUT_DISCRETE, pass the explicit channel count along with 748 // For CHANNEL_LAYOUT_DISCRETE, pass the explicit channel count along with
749 // the channel layout when creating an |AudioParameters| object. 749 // the channel layout when creating an |AudioParameters| object.
750 media::AudioParameters params(media::AudioParameters::AUDIO_PCM_LOW_LATENCY, 750 media::AudioParameters params(media::AudioParameters::AUDIO_PCM_LOW_LATENCY,
751 layout, static_cast<int>(sample_rate), 16, 751 layout, static_cast<int>(sample_rate), 32,
DaleCurtis 2016/11/01 18:51:37 Drop this change. I can't guarantee it'll plumb pr
Raymond Toy 2016/11/01 22:01:47 You're right. It's not plumbed through.
752 buffer_size); 752 buffer_size);
753 params.set_channels_for_discrete(channels); 753 params.set_channels_for_discrete(channels);
754 754
755 return new RendererWebAudioDeviceImpl( 755 return new RendererWebAudioDeviceImpl(
756 params, callback, session_id, static_cast<url::Origin>(security_origin)); 756 params, callback, session_id, static_cast<url::Origin>(security_origin));
757 } 757 }
758 758
759 bool RendererBlinkPlatformImpl::loadAudioResource( 759 bool RendererBlinkPlatformImpl::loadAudioResource(
760 blink::WebAudioBus* destination_bus, 760 blink::WebAudioBus* destination_bus,
761 const char* audio_file_data, 761 const char* audio_file_data,
(...skipping 564 matching lines...) Expand 10 before | Expand all | Expand 10 after
1326 return &trial_token_validator_; 1326 return &trial_token_validator_;
1327 } 1327 }
1328 1328
1329 void RendererBlinkPlatformImpl::workerContextCreated( 1329 void RendererBlinkPlatformImpl::workerContextCreated(
1330 const v8::Local<v8::Context>& worker) { 1330 const v8::Local<v8::Context>& worker) {
1331 GetContentClient()->renderer()->DidInitializeWorkerContextOnWorkerThread( 1331 GetContentClient()->renderer()->DidInitializeWorkerContextOnWorkerThread(
1332 worker); 1332 worker);
1333 } 1333 }
1334 1334
1335 } // namespace content 1335 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | media/audio/pulse/pulse_output.cc » ('j') | media/audio/pulse/pulse_output.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698