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

Side by Side Diff: content/browser/renderer_host/render_process_host_impl.cc

Issue 264793017: Implements RTP header dumping. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add WebRtcRtpDumpWriter Created 6 years, 7 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 (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 // Represents the browser side of the browser <--> renderer communication 5 // Represents the browser side of the browser <--> renderer communication
6 // channel. There will be one RenderProcessHost per renderer process. 6 // channel. There will be one RenderProcessHost per renderer process.
7 7
8 #include "content/browser/renderer_host/render_process_host_impl.h" 8 #include "content/browser/renderer_host/render_process_host_impl.h"
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 1494 matching lines...) Expand 10 before | Expand all | Expand 10 after
1505 BrowserThread::FILE, FROM_HERE, 1505 BrowserThread::FILE, FROM_HERE,
1506 base::Bind(&DisableAecDumpOnFileThread), 1506 base::Bind(&DisableAecDumpOnFileThread),
1507 base::Bind(&RenderProcessHostImpl::SendDisableAecDumpToRenderer, 1507 base::Bind(&RenderProcessHostImpl::SendDisableAecDumpToRenderer,
1508 weak_factory_.GetWeakPtr())); 1508 weak_factory_.GetWeakPtr()));
1509 } 1509 }
1510 1510
1511 void RenderProcessHostImpl::SetWebRtcLogMessageCallback( 1511 void RenderProcessHostImpl::SetWebRtcLogMessageCallback(
1512 base::Callback<void(const std::string&)> callback) { 1512 base::Callback<void(const std::string&)> callback) {
1513 webrtc_log_message_callback_ = callback; 1513 webrtc_log_message_callback_ = callback;
1514 } 1514 }
1515
1516 void RenderProcessHostImpl::SetWebRtcRtpPacketCallback(
1517 const WebRtcRtpPacketCallback& callback) {
1518 webrtc_rtp_packet_callback_ = callback;
1519 }
1520
1515 #endif 1521 #endif
1516 1522
1517 IPC::ChannelProxy* RenderProcessHostImpl::GetChannel() { 1523 IPC::ChannelProxy* RenderProcessHostImpl::GetChannel() {
1518 return channel_.get(); 1524 return channel_.get();
1519 } 1525 }
1520 1526
1521 void RenderProcessHostImpl::AddFilter(BrowserMessageFilter* filter) { 1527 void RenderProcessHostImpl::AddFilter(BrowserMessageFilter* filter) {
1522 channel_->AddFilter(filter->GetFilter()); 1528 channel_->AddFilter(filter->GetFilter());
1523 } 1529 }
1524 1530
(...skipping 367 matching lines...) Expand 10 before | Expand all | Expand 10 after
1892 gpu_message_filter_, 1898 gpu_message_filter_,
1893 route_id)); 1899 route_id));
1894 } 1900 }
1895 1901
1896 #if defined(ENABLE_WEBRTC) 1902 #if defined(ENABLE_WEBRTC)
1897 void RenderProcessHostImpl::WebRtcLogMessage(const std::string& message) { 1903 void RenderProcessHostImpl::WebRtcLogMessage(const std::string& message) {
1898 DCHECK_CURRENTLY_ON(BrowserThread::UI); 1904 DCHECK_CURRENTLY_ON(BrowserThread::UI);
1899 if (!webrtc_log_message_callback_.is_null()) 1905 if (!webrtc_log_message_callback_.is_null())
1900 webrtc_log_message_callback_.Run(message); 1906 webrtc_log_message_callback_.Run(message);
1901 } 1907 }
1908
1909 void RenderProcessHostImpl::OnRtpPacket(const uint8* packet,
1910 size_t length,
1911 bool incoming) {
1912 DCHECK_CURRENTLY_ON(BrowserThread::IO);
1913 if (!webrtc_rtp_packet_callback_.is_null())
1914 webrtc_rtp_packet_callback_.Run(packet, length, incoming);
1915 }
1902 #endif 1916 #endif
1903 1917
1904 scoped_refptr<ScreenOrientationDispatcherHost> 1918 scoped_refptr<ScreenOrientationDispatcherHost>
1905 RenderProcessHostImpl::screen_orientation_dispatcher_host() const { 1919 RenderProcessHostImpl::screen_orientation_dispatcher_host() const {
1906 return make_scoped_refptr(screen_orientation_dispatcher_host_); 1920 return make_scoped_refptr(screen_orientation_dispatcher_host_);
1907 } 1921 }
1908 1922
1909 void RenderProcessHostImpl::OnShutdownRequest() { 1923 void RenderProcessHostImpl::OnShutdownRequest() {
1910 // Don't shut down if there are active RenderViews, or if there are pending 1924 // Don't shut down if there are active RenderViews, or if there are pending
1911 // RenderViews being swapped back in. 1925 // RenderViews being swapped back in.
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after
2075 mojo::ScopedMessagePipeHandle handle) { 2089 mojo::ScopedMessagePipeHandle handle) {
2076 mojo_activation_required_ = true; 2090 mojo_activation_required_ = true;
2077 MaybeActivateMojo(); 2091 MaybeActivateMojo();
2078 2092
2079 mojo::AllocationScope scope; 2093 mojo::AllocationScope scope;
2080 mojo_application_host_->shell_client()->AcceptConnection(service_name, 2094 mojo_application_host_->shell_client()->AcceptConnection(service_name,
2081 handle.Pass()); 2095 handle.Pass());
2082 } 2096 }
2083 2097
2084 } // namespace content 2098 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698