OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #ifndef CHROME_RENDERER_MEDIA_CAST_IPC_DISPATCHER_H_ | 5 #ifndef CHROME_RENDERER_MEDIA_CAST_IPC_DISPATCHER_H_ |
6 #define CHROME_RENDERER_MEDIA_CAST_IPC_DISPATCHER_H_ | 6 #define CHROME_RENDERER_MEDIA_CAST_IPC_DISPATCHER_H_ |
7 | 7 |
8 #include "base/callback.h" | 8 #include "base/callback.h" |
9 #include "base/id_map.h" | 9 #include "base/id_map.h" |
10 #include "ipc/ipc_channel_proxy.h" | 10 #include "ipc/ipc_channel_proxy.h" |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
46 const media::cast::RtcpSenderInfo& sender_info, | 46 const media::cast::RtcpSenderInfo& sender_info, |
47 base::TimeTicks time_sent, | 47 base::TimeTicks time_sent, |
48 uint32 rtp_timestamp); | 48 uint32 rtp_timestamp); |
49 void OnRawEvents(int32 channel_id, | 49 void OnRawEvents(int32 channel_id, |
50 const std::vector<media::cast::PacketEvent>& packet_events, | 50 const std::vector<media::cast::PacketEvent>& packet_events, |
51 const std::vector<media::cast::FrameEvent>& frame_events); | 51 const std::vector<media::cast::FrameEvent>& frame_events); |
52 void OnRtt(int32 channel_id, uint32 ssrc, base::TimeDelta rtt); | 52 void OnRtt(int32 channel_id, uint32 ssrc, base::TimeDelta rtt); |
53 void OnRtcpCastMessage(int32 channel_id, | 53 void OnRtcpCastMessage(int32 channel_id, |
54 uint32 ssrc, | 54 uint32 ssrc, |
55 const media::cast::RtcpCastMessage& cast_message); | 55 const media::cast::RtcpCastMessage& cast_message); |
| 56 void OnReceivedPacket(int32 channel_id, const media::cast::Packet& packet); |
56 | 57 |
57 static CastIPCDispatcher* global_instance_; | 58 static CastIPCDispatcher* global_instance_; |
58 | 59 |
59 // For IPC Send(); must only be accesed on |io_message_loop_|. | 60 // For IPC Send(); must only be accesed on |io_message_loop_|. |
60 IPC::Sender* sender_; | 61 IPC::Sender* sender_; |
61 | 62 |
62 // Message loop on which IPC calls are driven. | 63 // Message loop on which IPC calls are driven. |
63 const scoped_refptr<base::MessageLoopProxy> io_message_loop_; | 64 const scoped_refptr<base::MessageLoopProxy> io_message_loop_; |
64 | 65 |
65 // A map of stream ids to delegates; must only be accessed on | 66 // A map of stream ids to delegates; must only be accessed on |
66 // |io_message_loop_|. | 67 // |io_message_loop_|. |
67 IDMap<CastTransportSenderIPC> id_map_; | 68 IDMap<CastTransportSenderIPC> id_map_; |
68 DISALLOW_COPY_AND_ASSIGN(CastIPCDispatcher); | 69 DISALLOW_COPY_AND_ASSIGN(CastIPCDispatcher); |
69 }; | 70 }; |
70 | 71 |
71 #endif // CHROME_RENDERER_MEDIA_CAST_IPC_DISPATCHER_H_ | 72 #endif // CHROME_RENDERER_MEDIA_CAST_IPC_DISPATCHER_H_ |
OLD | NEW |