MythTV  master
udppacketbuffer.h
Go to the documentation of this file.
1 /* -*- Mode: c++ -*-
2  * UDPPacketBuffer
3  * Copyright (c) 2012 Digital Nirvana, Inc.
4  * Distributed as part of MythTV under GPL v2 and later.
5  */
6 
7 #ifndef UDP_PACKET_BUFFER_H
8 #define UDP_PACKET_BUFFER_H
9 
10 #include "packetbuffer.h"
11 
13 {
14  public:
15  UDPPacketBuffer(unsigned int bitrate) : PacketBuffer(bitrate) {}
16 
18  void PushDataPacket(const UDPPacket &packet) override // PacketBuffer
19  {
20  m_available_packets.push_back(packet);
21  }
22 
24  void PushFECPacket(const UDPPacket &packet, unsigned int /*fec_stream_num*/) override // PacketBuffer
25  {
26  FreePacket(packet);
27  }
28 };
29 
30 #endif // UDP_PACKET_BUFFER_H
PacketBuffer::FreePacket
void FreePacket(const UDPPacket &packet)
Frees an RTPDataPacket returned by PopDataPacket.
Definition: packetbuffer.cpp:49
PacketBuffer
Definition: packetbuffer.h:15
UDPPacketBuffer::UDPPacketBuffer
UDPPacketBuffer(unsigned int bitrate)
Definition: udppacketbuffer.h:15
UDPPacketBuffer::PushDataPacket
void PushDataPacket(const UDPPacket &packet) override
Adds Raw UDP data packet.
Definition: udppacketbuffer.h:18
PacketBuffer::m_available_packets
QList< UDPPacket > m_available_packets
Ordered list of available packets.
Definition: packetbuffer.h:55
UDPPacketBuffer
Definition: udppacketbuffer.h:12
UDPPacket
UDP Packet.
Definition: udppacket.h:20
packetbuffer.h
UDPPacketBuffer::PushFECPacket
void PushFECPacket(const UDPPacket &packet, unsigned int) override
Frees the packet, there is no FEC used by Raw UDP.
Definition: udppacketbuffer.h:24