| OLD | NEW |
| 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/media_stream_dependency_factory.h" | 5 #include "content/renderer/media/media_stream_dependency_factory.h" |
| 6 | 6 |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
| (...skipping 417 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 428 } | 428 } |
| 429 #else | 429 #else |
| 430 // TODO(ronghuawu): Replace this call with InitializeSSL. | 430 // TODO(ronghuawu): Replace this call with InitializeSSL. |
| 431 net::EnsureNSSSSLInit(); | 431 net::EnsureNSSSSLInit(); |
| 432 #endif | 432 #endif |
| 433 | 433 |
| 434 scoped_ptr<cricket::WebRtcVideoDecoderFactory> decoder_factory; | 434 scoped_ptr<cricket::WebRtcVideoDecoderFactory> decoder_factory; |
| 435 scoped_ptr<cricket::WebRtcVideoEncoderFactory> encoder_factory; | 435 scoped_ptr<cricket::WebRtcVideoEncoderFactory> encoder_factory; |
| 436 | 436 |
| 437 const CommandLine* cmd_line = CommandLine::ForCurrentProcess(); | 437 const CommandLine* cmd_line = CommandLine::ForCurrentProcess(); |
| 438 scoped_refptr<RendererGpuVideoAcceleratorFactories> gpu_factories = | 438 scoped_refptr<media::GpuVideoAcceleratorFactories> gpu_factories = |
| 439 RenderThreadImpl::current()->GetGpuFactories(); | 439 RenderThreadImpl::current()->GetGpuFactories(); |
| 440 if (!cmd_line->HasSwitch(switches::kDisableWebRtcHWDecoding)) { | 440 if (!cmd_line->HasSwitch(switches::kDisableWebRtcHWDecoding)) { |
| 441 if (gpu_factories) | 441 if (gpu_factories) |
| 442 decoder_factory.reset(new RTCVideoDecoderFactory(gpu_factories)); | 442 decoder_factory.reset(new RTCVideoDecoderFactory(gpu_factories)); |
| 443 } | 443 } |
| 444 | 444 |
| 445 if (!cmd_line->HasSwitch(switches::kDisableWebRtcHWEncoding)) { | 445 if (!cmd_line->HasSwitch(switches::kDisableWebRtcHWEncoding)) { |
| 446 if (gpu_factories) | 446 if (gpu_factories) |
| 447 encoder_factory.reset(new RTCVideoEncoderFactory(gpu_factories)); | 447 encoder_factory.reset(new RTCVideoEncoderFactory(gpu_factories)); |
| 448 } | 448 } |
| (...skipping 326 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 775 } | 775 } |
| 776 | 776 |
| 777 void MediaStreamDependencyFactory::EnsureWebRtcAudioDeviceImpl() { | 777 void MediaStreamDependencyFactory::EnsureWebRtcAudioDeviceImpl() { |
| 778 if (audio_device_) | 778 if (audio_device_) |
| 779 return; | 779 return; |
| 780 | 780 |
| 781 audio_device_ = new WebRtcAudioDeviceImpl(); | 781 audio_device_ = new WebRtcAudioDeviceImpl(); |
| 782 } | 782 } |
| 783 | 783 |
| 784 } // namespace content | 784 } // namespace content |
| OLD | NEW |