OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2017 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2017 The WebRTC project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
11 #include "webrtc/base/checks.h" | 11 #include "webrtc/base/checks.h" |
12 #include "webrtc/call/rtp_demuxer.h" | 12 #include "webrtc/call/rtp_demuxer.h" |
| 13 #include "webrtc/call/rtp_packet_sink_interface.h" |
13 #include "webrtc/modules/rtp_rtcp/source/rtp_packet_received.h" | 14 #include "webrtc/modules/rtp_rtcp/source/rtp_packet_received.h" |
14 | 15 |
15 namespace webrtc { | 16 namespace webrtc { |
16 | 17 |
17 namespace { | 18 namespace { |
18 | 19 |
19 template <typename Key, typename Value> | 20 template <typename Key, typename Value> |
20 bool MultimapAssociationExists(const std::multimap<Key, Value>& multimap, | 21 bool MultimapAssociationExists(const std::multimap<Key, Value>& multimap, |
21 Key key, | 22 Key key, |
22 Value val) { | 23 Value val) { |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
58 bool found = false; | 59 bool found = false; |
59 auto it_range = sinks_.equal_range(packet.Ssrc()); | 60 auto it_range = sinks_.equal_range(packet.Ssrc()); |
60 for (auto it = it_range.first; it != it_range.second; ++it) { | 61 for (auto it = it_range.first; it != it_range.second; ++it) { |
61 found = true; | 62 found = true; |
62 it->second->OnRtpPacket(packet); | 63 it->second->OnRtpPacket(packet); |
63 } | 64 } |
64 return found; | 65 return found; |
65 } | 66 } |
66 | 67 |
67 } // namespace webrtc | 68 } // namespace webrtc |
OLD | NEW |