Chromium Code Reviews| 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/rtc_peer_connection_handler.h" | 5 #include "content/renderer/media/rtc_peer_connection_handler.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 #include <utility> | 8 #include <utility> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| 11 #include "base/command_line.h" | 11 #include "base/command_line.h" |
| 12 #include "base/debug/trace_event.h" | 12 #include "base/debug/trace_event.h" |
| 13 #include "base/logging.h" | 13 #include "base/logging.h" |
| 14 #include "base/memory/scoped_ptr.h" | 14 #include "base/memory/scoped_ptr.h" |
| 15 #include "base/metrics/histogram.h" | 15 #include "base/metrics/histogram.h" |
| 16 #include "base/stl_util.h" | 16 #include "base/stl_util.h" |
| 17 #include "base/strings/utf_string_conversions.h" | 17 #include "base/strings/utf_string_conversions.h" |
| 18 #include "content/public/common/content_switches.h" | 18 #include "content/public/common/content_switches.h" |
| 19 #include "content/renderer/media/media_stream_dependency_factory.h" | |
| 20 #include "content/renderer/media/media_stream_track.h" | 19 #include "content/renderer/media/media_stream_track.h" |
| 21 #include "content/renderer/media/peer_connection_tracker.h" | 20 #include "content/renderer/media/peer_connection_tracker.h" |
| 22 #include "content/renderer/media/remote_media_stream_impl.h" | 21 #include "content/renderer/media/remote_media_stream_impl.h" |
| 23 #include "content/renderer/media/rtc_data_channel_handler.h" | 22 #include "content/renderer/media/rtc_data_channel_handler.h" |
| 24 #include "content/renderer/media/rtc_dtmf_sender_handler.h" | 23 #include "content/renderer/media/rtc_dtmf_sender_handler.h" |
| 25 #include "content/renderer/media/rtc_media_constraints.h" | 24 #include "content/renderer/media/rtc_media_constraints.h" |
| 26 #include "content/renderer/media/webrtc/webrtc_media_stream_adapter.h" | 25 #include "content/renderer/media/webrtc/webrtc_media_stream_adapter.h" |
| 27 #include "content/renderer/media/webrtc_audio_capturer.h" | 26 #include "content/renderer/media/webrtc_audio_capturer.h" |
| 28 #include "content/renderer/media/webrtc_audio_device_impl.h" | 27 #include "content/renderer/media/webrtc_audio_device_impl.h" |
| 29 #include "content/renderer/media/webrtc_uma_histograms.h" | 28 #include "content/renderer/media/webrtc_uma_histograms.h" |
| 30 #include "content/renderer/render_thread_impl.h" | 29 #include "content/renderer/render_thread_impl.h" |
|
no longer working on chromium
2014/05/15 08:17:21
nit, add include peer_connection_dependency_factor
| |
| 31 #include "third_party/WebKit/public/platform/WebMediaConstraints.h" | 30 #include "third_party/WebKit/public/platform/WebMediaConstraints.h" |
| 32 #include "third_party/WebKit/public/platform/WebMediaStreamSource.h" | 31 #include "third_party/WebKit/public/platform/WebMediaStreamSource.h" |
| 33 #include "third_party/WebKit/public/platform/WebRTCConfiguration.h" | 32 #include "third_party/WebKit/public/platform/WebRTCConfiguration.h" |
| 34 #include "third_party/WebKit/public/platform/WebRTCDataChannelInit.h" | 33 #include "third_party/WebKit/public/platform/WebRTCDataChannelInit.h" |
| 35 #include "third_party/WebKit/public/platform/WebRTCICECandidate.h" | 34 #include "third_party/WebKit/public/platform/WebRTCICECandidate.h" |
| 36 #include "third_party/WebKit/public/platform/WebRTCSessionDescription.h" | 35 #include "third_party/WebKit/public/platform/WebRTCSessionDescription.h" |
| 37 #include "third_party/WebKit/public/platform/WebRTCSessionDescriptionRequest.h" | 36 #include "third_party/WebKit/public/platform/WebRTCSessionDescriptionRequest.h" |
| 38 #include "third_party/WebKit/public/platform/WebRTCVoidRequest.h" | 37 #include "third_party/WebKit/public/platform/WebRTCVoidRequest.h" |
| 39 #include "third_party/WebKit/public/platform/WebURL.h" | 38 #include "third_party/WebKit/public/platform/WebURL.h" |
| 40 | 39 |
| (...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 311 } | 310 } |
| 312 | 311 |
| 313 void LocalRTCStatsResponse::addStatistic(size_t report, | 312 void LocalRTCStatsResponse::addStatistic(size_t report, |
| 314 blink::WebString name, | 313 blink::WebString name, |
| 315 blink::WebString value) { | 314 blink::WebString value) { |
| 316 impl_.addStatistic(report, name, value); | 315 impl_.addStatistic(report, name, value); |
| 317 } | 316 } |
| 318 | 317 |
| 319 RTCPeerConnectionHandler::RTCPeerConnectionHandler( | 318 RTCPeerConnectionHandler::RTCPeerConnectionHandler( |
| 320 blink::WebRTCPeerConnectionHandlerClient* client, | 319 blink::WebRTCPeerConnectionHandlerClient* client, |
| 321 MediaStreamDependencyFactory* dependency_factory) | 320 PeerConnectionDependencyFactory* dependency_factory) |
| 322 : client_(client), | 321 : client_(client), |
| 323 dependency_factory_(dependency_factory), | 322 dependency_factory_(dependency_factory), |
| 324 frame_(NULL), | 323 frame_(NULL), |
| 325 peer_connection_tracker_(NULL), | 324 peer_connection_tracker_(NULL), |
| 326 num_data_channels_created_(0) { | 325 num_data_channels_created_(0) { |
| 327 } | 326 } |
| 328 | 327 |
| 329 RTCPeerConnectionHandler::~RTCPeerConnectionHandler() { | 328 RTCPeerConnectionHandler::~RTCPeerConnectionHandler() { |
| 330 if (peer_connection_tracker_) | 329 if (peer_connection_tracker_) |
| 331 peer_connection_tracker_->UnregisterPeerConnection(this); | 330 peer_connection_tracker_->UnregisterPeerConnection(this); |
| (...skipping 529 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 861 webrtc::SessionDescriptionInterface* native_desc = | 860 webrtc::SessionDescriptionInterface* native_desc = |
| 862 dependency_factory_->CreateSessionDescription(type, sdp, error); | 861 dependency_factory_->CreateSessionDescription(type, sdp, error); |
| 863 | 862 |
| 864 LOG_IF(ERROR, !native_desc) << "Failed to create native session description." | 863 LOG_IF(ERROR, !native_desc) << "Failed to create native session description." |
| 865 << " Type: " << type << " SDP: " << sdp; | 864 << " Type: " << type << " SDP: " << sdp; |
| 866 | 865 |
| 867 return native_desc; | 866 return native_desc; |
| 868 } | 867 } |
| 869 | 868 |
| 870 } // namespace content | 869 } // namespace content |
| OLD | NEW |