tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

rtp_packet_sender.h (1243B)


      1 /*
      2 *  Copyright (c) 2019 The WebRTC project authors. All Rights Reserved.
      3 *
      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
      6 *  tree. An additional intellectual property rights grant can be found
      7 *  in the file PATENTS.  All contributing project authors may
      8 *  be found in the AUTHORS file in the root of the source tree.
      9 */
     10 
     11 #ifndef API_RTP_PACKET_SENDER_H_
     12 #define API_RTP_PACKET_SENDER_H_
     13 
     14 #include <cstdint>
     15 #include <memory>
     16 #include <vector>
     17 
     18 namespace webrtc {
     19 
     20 class RtpPacketToSend;
     21 
     22 class RtpPacketSender {
     23 public:
     24  virtual ~RtpPacketSender() = default;
     25 
     26  // Insert a set of packets into queue, for eventual transmission. Based on the
     27  // type of packets, they will be prioritized and scheduled relative to other
     28  // packets and the current target send rate.
     29  virtual void EnqueuePackets(
     30      std::vector<std::unique_ptr<RtpPacketToSend>> packets) = 0;
     31 
     32  // Clear any pending packets with the given SSRC from the queue.
     33  // TODO(crbug.com/1395081): Make pure virtual when downstream code has been
     34  // updated.
     35  virtual void RemovePacketsForSsrc(uint32_t /* ssrc */) {}
     36 };
     37 
     38 }  // namespace webrtc
     39 
     40 #endif  // API_RTP_PACKET_SENDER_H_