SDRAngel
4.11.5
Developer docs for <a href="https://github.com/f4exb/sdrangel">SDRangel<\a>, an Open Source Qt5 / OpenGL 3.0+ SDR and signal analyzer frontend to various hardware.
|
#include <rtptransmitter.h>
Public Types | |
enum | TransmissionProtocol { IPv4UDPProto, IPv6UDPProto, TCPProto, ExternalProto, UserDefinedProto } |
enum | ReceiveMode { AcceptAll, AcceptSome, IgnoreSome } |
Public Member Functions | |
virtual | ~RTPTransmitter () |
virtual int | Init ()=0 |
virtual int | Create (std::size_t maxpacksize, const RTPTransmissionParams *transparams)=0 |
virtual int | BindSockets ()=0 |
virtual void | Destroy ()=0 |
virtual RTPTransmissionInfo * | GetTransmissionInfo ()=0 |
virtual void | DeleteTransmissionInfo (RTPTransmissionInfo *inf)=0 |
virtual bool | ComesFromThisTransmitter (const RTPAddress &addr)=0 |
virtual std::size_t | GetHeaderOverhead ()=0 |
virtual int | SendRTPData (const void *data, std::size_t len)=0 |
virtual int | SendRTCPData (const void *data, std::size_t len)=0 |
virtual int | AddDestination (const RTPAddress &addr)=0 |
virtual int | DeleteDestination (const RTPAddress &addr)=0 |
virtual void | ClearDestinations ()=0 |
virtual bool | SupportsMulticasting ()=0 |
virtual int | JoinMulticastGroup (const RTPAddress &addr)=0 |
virtual int | LeaveMulticastGroup (const RTPAddress &addr)=0 |
virtual int | SetReceiveMode (RTPTransmitter::ReceiveMode m)=0 |
virtual int | AddToIgnoreList (const RTPAddress &addr)=0 |
virtual int | DeleteFromIgnoreList (const RTPAddress &addr)=0 |
virtual void | ClearIgnoreList ()=0 |
virtual int | AddToAcceptList (const RTPAddress &addr)=0 |
virtual int | DeleteFromAcceptList (const RTPAddress &addr)=0 |
virtual void | ClearAcceptList ()=0 |
virtual int | SetMaximumPacketSize (std::size_t s)=0 |
virtual RTPRawPacket * | GetNextPacket ()=0 |
Protected Member Functions | |
RTPTransmitter () | |
Abstract class from which actual transmission components should be derived. Abstract class from which actual transmission components should be derived. The abstract class RTPTransmitter specifies the interface for actual transmission components. Currently, three implementations exist: an UDP over IPv4 transmitter, an UDP over IPv6 transmitter and a transmitter which can be used to use an external transmission mechanism.
Definition at line 62 of file rtptransmitter.h.
Three kind of receive modes can be specified.
Definition at line 80 of file rtptransmitter.h.
Used to identify a specific transmitter. If UserDefinedProto is used in the RTPSession::Create function, the RTPSession virtual member function NewUserDefinedTransmitter will be called to create a transmission component.
Definition at line 70 of file rtptransmitter.h.
|
inlineprotected |
Constructor in which you can specify a memory manager to use.
Definition at line 88 of file rtptransmitter.h.
References qrtplib::RTPTimeInitializerObject::Dummy(), and qrtplib::timeinit.
|
inlinevirtual |
Definition at line 93 of file rtptransmitter.h.
References AddDestination(), AddToAcceptList(), AddToIgnoreList(), BindSockets(), ClearAcceptList(), ClearDestinations(), ClearIgnoreList(), ComesFromThisTransmitter(), Create(), DeleteDestination(), DeleteFromAcceptList(), DeleteFromIgnoreList(), DeleteTransmissionInfo(), Destroy(), GetHeaderOverhead(), GetNextPacket(), GetTransmissionInfo(), Init(), JoinMulticastGroup(), LeaveMulticastGroup(), SendRTCPData(), SendRTPData(), SetMaximumPacketSize(), SetReceiveMode(), and SupportsMulticasting().
|
pure virtual |
Adds the address specified by addr
to the list of destinations.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::AddDestination(), and ~RTPTransmitter().
|
pure virtual |
Adds addr
to the list of addresses to accept.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::AddToAcceptList(), and ~RTPTransmitter().
|
pure virtual |
Adds addr
to the list of addresses to ignore.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::AddToIgnoreList(), and ~RTPTransmitter().
|
pure virtual |
Bind the RTP and RTCP sockets to ports that were set at creation time
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by ~RTPTransmitter().
|
pure virtual |
Clears the list of addresses to accept.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::ClearAcceptList(), and ~RTPTransmitter().
|
pure virtual |
Clears the list of destinations.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::ClearDestinations(), and ~RTPTransmitter().
|
pure virtual |
Clears the list of addresses to ignore.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::ClearIgnoreList(), and ~RTPTransmitter().
|
pure virtual |
Returns true
if the address specified by addr
is one of the addresses of the transmitter.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by ~RTPTransmitter().
|
pure virtual |
Prepares the component to be used. Prepares the component to be used. The parameter maxpacksize
specifies the maximum size a packet can have: if the packet is larger it will not be transmitted. The transparams
parameter specifies a pointer to an RTPTransmissionParams instance. This is also an abstract class and each actual component will define its own parameters by inheriting a class from RTPTransmissionParams. If transparams
is NULL, the default transmission parameters for the component will be used.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by ~RTPTransmitter().
|
pure virtual |
Deletes the address specified by addr
from the list of destinations.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::DeleteDestination(), and ~RTPTransmitter().
|
pure virtual |
Deletes addr
from the list of addresses to accept.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::DeleteFromAcceptList(), and ~RTPTransmitter().
|
pure virtual |
Deletes addr
from the list of addresses to accept.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::DeleteFromIgnoreList(), and ~RTPTransmitter().
|
pure virtual |
Deallocates the information returned by RTPTransmitter::GetTransmissionInfo . Deallocates the information returned by RTPTransmitter::GetTransmissionInfo .
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::DeleteTransmissionInfo(), and ~RTPTransmitter().
|
pure virtual |
By calling this function, buffers are cleared and the component cannot be used anymore. By calling this function, buffers are cleared and the component cannot be used anymore. Only when the Create function is called again can the component be used again.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by ~RTPTransmitter().
|
pure virtual |
Returns the amount of bytes that will be added to the RTP packet by the underlying layers (excluding the link layer).
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::InternalCreate(), and ~RTPTransmitter().
|
pure virtual |
Returns the raw data of a received RTP packet in an RTPRawPacket instance.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::ProcessPolledData(), and ~RTPTransmitter().
|
pure virtual |
Returns additional information about the transmitter. This function returns an instance of a subclass of RTPTransmissionInfo which will give some additional information about the transmitter (a list of local IP addresses for example). Currently, either an instance of RTPUDPv4TransmissionInfo or RTPUDPv6TransmissionInfo is returned, depending on the type of the transmitter. The user has to deallocate the returned instance when it is no longer needed, which can be done using RTPTransmitter::DeleteTransmissionInfo.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::GetTransmissionInfo(), and ~RTPTransmitter().
|
pure virtual |
This function must be called before the transmission component can be used.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by ~RTPTransmitter().
|
pure virtual |
Joins the multicast group specified by addr
.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::JoinMulticastGroup(), and ~RTPTransmitter().
|
pure virtual |
Leaves the multicast group specified by addr
.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::LeaveMulticastGroup(), and ~RTPTransmitter().
|
pure virtual |
Send a packet with length len
containing data
to all RTCP addresses of the current destination list.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::SendRawData(), qrtplib::RTPSession::SendRTCPData(), and ~RTPTransmitter().
|
pure virtual |
Send a packet with length len
containing data
to all RTP addresses of the current destination list.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::SendRawData(), qrtplib::RTPSession::SendRTPData(), and ~RTPTransmitter().
|
pure virtual |
Sets the maximum packet size which the transmitter should allow to s
.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::Create(), qrtplib::RTPSession::SetMaximumPacketSize(), and ~RTPTransmitter().
|
pure virtual |
Sets the receive mode. Sets the receive mode to m
, which is one of the following: RTPTransmitter::AcceptAll, RTPTransmitter::AcceptSome or RTPTransmitter::IgnoreSome. Note that if the receive mode is changed, all information about the addresses to ignore to accept is lost.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::InternalCreate(), qrtplib::RTPSession::SetReceiveMode(), and ~RTPTransmitter().
|
pure virtual |
Returns true
if the transmission component supports multicasting.
Implemented in qrtplib::RTPUDPTransmitter.
Referenced by qrtplib::RTPSession::SupportsMulticasting(), and ~RTPTransmitter().