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

Side by Side Diff: content/renderer/media/audio_device_factory.cc

Issue 2083633002: AudioOutputDevice authorization timeout decreased (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Changed timeout to 900 ms Created 4 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | 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/renderer/media/audio_device_factory.h" 5 #include "content/renderer/media/audio_device_factory.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "content/common/content_constants_internal.h" 10 #include "content/common/content_constants_internal.h"
11 #include "content/renderer/media/audio_input_message_filter.h" 11 #include "content/renderer/media/audio_input_message_filter.h"
12 #include "content/renderer/media/audio_message_filter.h" 12 #include "content/renderer/media/audio_message_filter.h"
13 #include "content/renderer/media/audio_renderer_mixer_manager.h" 13 #include "content/renderer/media/audio_renderer_mixer_manager.h"
14 #include "content/renderer/render_thread_impl.h" 14 #include "content/renderer/render_thread_impl.h"
15 #include "media/audio/audio_input_device.h" 15 #include "media/audio/audio_input_device.h"
16 #include "media/audio/audio_output_device.h" 16 #include "media/audio/audio_output_device.h"
17 #include "media/base/audio_renderer_mixer_input.h" 17 #include "media/base/audio_renderer_mixer_input.h"
18 #include "url/origin.h" 18 #include "url/origin.h"
19 19
20 namespace content { 20 namespace content {
21 21
22 // static 22 // static
23 AudioDeviceFactory* AudioDeviceFactory::factory_ = NULL; 23 AudioDeviceFactory* AudioDeviceFactory::factory_ = NULL;
24 24
25 namespace { 25 namespace {
26 const int64_t kMaxAuthorizationTimeoutMs = 4000; 26 const int64_t kMaxAuthorizationTimeoutMs = 900;
27 27
28 scoped_refptr<media::AudioOutputDevice> NewOutputDevice( 28 scoped_refptr<media::AudioOutputDevice> NewOutputDevice(
29 int render_frame_id, 29 int render_frame_id,
30 int session_id, 30 int session_id,
31 const std::string& device_id, 31 const std::string& device_id,
32 const url::Origin& security_origin) { 32 const url::Origin& security_origin) {
33 AudioMessageFilter* const filter = AudioMessageFilter::Get(); 33 AudioMessageFilter* const filter = AudioMessageFilter::Get();
34 scoped_refptr<media::AudioOutputDevice> device(new media::AudioOutputDevice( 34 scoped_refptr<media::AudioOutputDevice> device(new media::AudioOutputDevice(
35 filter->CreateAudioOutputIPC(render_frame_id), filter->io_task_runner(), 35 filter->CreateAudioOutputIPC(render_frame_id), filter->io_task_runner(),
36 session_id, device_id, security_origin, 36 session_id, device_id, security_origin,
(...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after
177 device_id, security_origin); 177 device_id, security_origin);
178 if (sink) 178 if (sink)
179 return sink; 179 return sink;
180 } 180 }
181 181
182 return NewOutputDevice(render_frame_id, session_id, device_id, 182 return NewOutputDevice(render_frame_id, session_id, device_id,
183 security_origin); 183 security_origin);
184 } 184 }
185 185
186 } // namespace content 186 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698