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

Unified Diff: content/browser/renderer_host/p2p/socket_host.h

Issue 159353002: This CL adds methods to manipulate RTP header extension, particularly (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 9 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/renderer_host/p2p/socket_host.h
diff --git a/content/browser/renderer_host/p2p/socket_host.h b/content/browser/renderer_host/p2p/socket_host.h
index a62401278a73aec70c6500af696f1b38d70956ee..9f47da48c5d3e65cbb9a5efcf4dc4be620cd2d87 100644
--- a/content/browser/renderer_host/p2p/socket_host.h
+++ b/content/browser/renderer_host/p2p/socket_host.h
@@ -25,6 +25,24 @@ struct PacketOptions;
namespace content {
class P2PMessageThrottler;
+namespace packet_processing_helpers {
+
+// This method can handle only RTP packet, otherwise this method must not be
+// called. It will try to do, 1. update absolute send time extension header
+// if present with current time and 2. update HMAC in RTP packet.
+bool ApplyPacketOptions(char* data, int length,
+ const talk_base::PacketOptions& options);
+
+// Helper method which finds RTP ofset and length if the packet is encapsulated
+// in a TURN Channel Message or TURN Send Indication message.
+bool GetRtpPacketStartPositionAndLength(char* data, int length,
+ int* rtp_start_pos,
+ int* rtp_packet_length);
+// Helper method which updates absoulute send time extension if present.
+bool UpdateRtpAbsSendTimeExtn(char* rtp, int length, int extension_id);
+
+} // packet_processing_helpers
+
// Base class for P2P sockets.
class CONTENT_EXPORT P2PSocketHost {
public:
@@ -53,7 +71,6 @@ class CONTENT_EXPORT P2PSocketHost {
virtual bool SetOption(P2PSocketOption option, int value) = 0;
protected:
- friend class P2PSocketHostTcpTestBase;
// TODO(mallinath) - Remove this below enum and use one defined in
// libjingle/souce/talk/p2p/base/stun.h

Powered by Google App Engine
This is Rietveld 408576698