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.
Public Member Functions | Private Attributes | List of all members
qrtplib::RTPUDPTransmissionParams Class Reference

#include <rtpudptransmitter.h>

+ Inheritance diagram for qrtplib::RTPUDPTransmissionParams:
+ Collaboration diagram for qrtplib::RTPUDPTransmissionParams:

Public Member Functions

 RTPUDPTransmissionParams ()
 
void SetBindIP (const QHostAddress &bindAddress)
 
void SetMulticastInterface (const QNetworkInterface &mcastInterface)
 
void SetPortbase (uint16_t pbase)
 
QHostAddress GetBindIP () const
 
QNetworkInterface GetMulticastInterface () const
 
uint16_t GetPortbase () const
 
void SetRTPSendBufferSize (int s)
 
void SetRTPReceiveBufferSize (int s)
 
void SetRTCPSendBufferSize (int s)
 
void SetRTCPReceiveBufferSize (int s)
 
void SetRTCPMultiplexing (bool f)
 
void SetAllowOddPortbase (bool f)
 
void SetForcedRTCPPort (uint16_t rtcpport)
 
void SetUseExistingSockets (QUdpSocket *rtpsocket, QUdpSocket *rtcpsocket)
 
int GetRTPSendBufferSize () const
 
int GetRTPReceiveBufferSize () const
 
int GetRTCPSendBufferSize () const
 
int GetRTCPReceiveBufferSize () const
 
bool GetRTCPMultiplexing () const
 
bool GetAllowOddPortbase () const
 
uint16_t GetForcedRTCPPort () const
 
bool GetUseExistingSockets (QUdpSocket **rtpsocket, QUdpSocket **rtcpsocket) const
 
- Public Member Functions inherited from qrtplib::RTPTransmissionParams
virtual ~RTPTransmissionParams ()
 
RTPTransmitter::TransmissionProtocol GetTransmissionProtocol () const
 

Private Attributes

QHostAddress m_bindAddress
 
QNetworkInterface m_mcastInterface
 
uint16_t m_portbase
 
int m_rtpsendbufsz
 
int m_rtprecvbufsz
 
int m_rtcpsendbufsz
 
int m_rtcprecvbufsz
 
bool m_rtcpmux
 
bool m_allowoddportbase
 
uint16_t m_forcedrtcpport
 
QUdpSocket * m_rtpsock
 
QUdpSocket * m_rtcpsock
 
bool m_useexistingsockets
 

Additional Inherited Members

- Protected Member Functions inherited from qrtplib::RTPTransmissionParams
 RTPTransmissionParams (RTPTransmitter::TransmissionProtocol p)
 

Detailed Description

Parameters for the UDP transmitter.

Definition at line 61 of file rtpudptransmitter.h.

Constructor & Destructor Documentation

◆ RTPUDPTransmissionParams()

qrtplib::RTPUDPTransmissionParams::RTPUDPTransmissionParams ( )
inline

Definition at line 225 of file rtpudptransmitter.h.

References m_allowoddportbase, m_forcedrtcpport, m_portbase, m_rtcpmux, m_rtcprecvbufsz, m_rtcpsendbufsz, m_rtcpsock, m_rtprecvbufsz, m_rtpsendbufsz, m_rtpsock, m_useexistingsockets, RTPUDPV4TRANS_DEFAULTPORTBASE, RTPUDPV4TRANS_RTCPRECEIVEBUFFER, RTPUDPV4TRANS_RTCPTRANSMITBUFFER, RTPUDPV4TRANS_RTPRECEIVEBUFFER, and RTPUDPV4TRANS_RTPTRANSMITBUFFER.

225  :
227 {
233  m_rtcpmux = false;
234  m_allowoddportbase = false;
235  m_forcedrtcpport = 0;
236  m_rtpsock = 0;
237  m_rtcpsock = 0;
238  m_useexistingsockets = false;
239 }
#define RTPUDPV4TRANS_RTCPTRANSMITBUFFER
#define RTPUDPV4TRANS_DEFAULTPORTBASE
#define RTPUDPV4TRANS_RTCPRECEIVEBUFFER
#define RTPUDPV4TRANS_RTPRECEIVEBUFFER
#define RTPUDPV4TRANS_RTPTRANSMITBUFFER
RTPTransmissionParams(RTPTransmitter::TransmissionProtocol p)

Member Function Documentation

◆ GetAllowOddPortbase()

bool qrtplib::RTPUDPTransmissionParams::GetAllowOddPortbase ( ) const
inline

If true, any RTP portbase will be allowed, not just even numbers.

Definition at line 186 of file rtpudptransmitter.h.

Referenced by qrtplib::RTPUDPTransmitter::Create().

187  {
188  return m_allowoddportbase;
189  }
+ Here is the caller graph for this function:

◆ GetBindIP()

QHostAddress qrtplib::RTPUDPTransmissionParams::GetBindIP ( ) const
inline

Returns the IP address which will be used to bind the sockets.

Definition at line 85 of file rtpudptransmitter.h.

Referenced by qrtplib::RTPUDPTransmitter::Create().

86  {
87  return m_bindAddress;
88  }
+ Here is the caller graph for this function:

◆ GetForcedRTCPPort()

uint16_t qrtplib::RTPUDPTransmissionParams::GetForcedRTCPPort ( ) const
inline

If non-zero, the specified port will be used to receive RTCP traffic.

Definition at line 192 of file rtpudptransmitter.h.

Referenced by qrtplib::RTPUDPTransmitter::Create().

193  {
194  return m_forcedrtcpport;
195  }
+ Here is the caller graph for this function:

◆ GetMulticastInterface()

QNetworkInterface qrtplib::RTPUDPTransmissionParams::GetMulticastInterface ( ) const
inline

Returns the multicast interface IP address.

Definition at line 91 of file rtpudptransmitter.h.

Referenced by qrtplib::RTPUDPTransmitter::Create().

92  {
93  return m_mcastInterface;
94  }
+ Here is the caller graph for this function:

◆ GetPortbase()

uint16_t qrtplib::RTPUDPTransmissionParams::GetPortbase ( ) const
inline

Returns the RTP portbase which will be used (default is 5000).

Definition at line 97 of file rtpudptransmitter.h.

Referenced by qrtplib::RTPUDPTransmitter::Create().

98  {
99  return m_portbase;
100  }
+ Here is the caller graph for this function:

◆ GetRTCPMultiplexing()

bool qrtplib::RTPUDPTransmissionParams::GetRTCPMultiplexing ( ) const
inline

Returns a flag indicating if RTCP traffic will be multiplexed over the RTP channel.

Definition at line 180 of file rtpudptransmitter.h.

Referenced by qrtplib::RTPUDPTransmitter::Create().

181  {
182  return m_rtcpmux;
183  }
+ Here is the caller graph for this function:

◆ GetRTCPReceiveBufferSize()

int qrtplib::RTPUDPTransmissionParams::GetRTCPReceiveBufferSize ( ) const
inline

Returns the RTCP socket's receive buffer size.

Definition at line 174 of file rtpudptransmitter.h.

Referenced by qrtplib::RTPUDPTransmitter::Create().

175  {
176  return m_rtcprecvbufsz;
177  }
+ Here is the caller graph for this function:

◆ GetRTCPSendBufferSize()

int qrtplib::RTPUDPTransmissionParams::GetRTCPSendBufferSize ( ) const
inline

Returns the RTCP socket's send buffer size.

Definition at line 168 of file rtpudptransmitter.h.

169  {
170  return m_rtcpsendbufsz;
171  }

◆ GetRTPReceiveBufferSize()

int qrtplib::RTPUDPTransmissionParams::GetRTPReceiveBufferSize ( ) const
inline

Returns the RTP socket's receive buffer size.

Definition at line 162 of file rtpudptransmitter.h.

Referenced by qrtplib::RTPUDPTransmitter::Create().

163  {
164  return m_rtprecvbufsz;
165  }
+ Here is the caller graph for this function:

◆ GetRTPSendBufferSize()

int qrtplib::RTPUDPTransmissionParams::GetRTPSendBufferSize ( ) const
inline

Returns the RTP socket's send buffer size.

Definition at line 156 of file rtpudptransmitter.h.

157  {
158  return m_rtpsendbufsz;
159  }

◆ GetUseExistingSockets()

bool qrtplib::RTPUDPTransmissionParams::GetUseExistingSockets ( QUdpSocket **  rtpsocket,
QUdpSocket **  rtcpsocket 
) const
inline

Returns true and fills in sockets if existing sockets were set using RTPUDPv4TransmissionParams::SetUseExistingSockets.

Definition at line 199 of file rtpudptransmitter.h.

Referenced by qrtplib::RTPUDPTransmitter::Create().

200  {
201  if (!m_useexistingsockets) {
202  return false;
203  }
204 
205  *rtpsocket = m_rtpsock;
206  *rtcpsocket = m_rtcpsock;
207 
208  return true;
209  }
+ Here is the caller graph for this function:

◆ SetAllowOddPortbase()

void qrtplib::RTPUDPTransmissionParams::SetAllowOddPortbase ( bool  f)
inline

Can be used to allow the RTP port base to be any number, not just even numbers.

Definition at line 133 of file rtpudptransmitter.h.

134  {
135  m_allowoddportbase = f;
136  }

◆ SetBindIP()

void qrtplib::RTPUDPTransmissionParams::SetBindIP ( const QHostAddress &  bindAddress)
inline

Sets the IP address which is used to bind the sockets to bindAddress.

Definition at line 67 of file rtpudptransmitter.h.

67  {
68  m_bindAddress = bindAddress;
69  }

◆ SetForcedRTCPPort()

void qrtplib::RTPUDPTransmissionParams::SetForcedRTCPPort ( uint16_t  rtcpport)
inline

Force the RTCP socket to use a specific port, not necessarily one more than the RTP port (set this to zero to disable).

Definition at line 140 of file rtpudptransmitter.h.

141  {
142  m_forcedrtcpport = rtcpport;
143  }

◆ SetMulticastInterface()

void qrtplib::RTPUDPTransmissionParams::SetMulticastInterface ( const QNetworkInterface &  mcastInterface)
inline

Sets the multicast interface IP address.

Definition at line 72 of file rtpudptransmitter.h.

72  {
73  m_mcastInterface = mcastInterface;
74  }

◆ SetPortbase()

void qrtplib::RTPUDPTransmissionParams::SetPortbase ( uint16_t  pbase)
inline

Sets the RTP portbase to pbase, which has to be an even number unless RTPUDPv4TransmissionParams::SetAllowOddPortbase was called; a port number of zero will cause a port to be chosen automatically.

Definition at line 79 of file rtpudptransmitter.h.

80  {
81  m_portbase = pbase;
82  }

◆ SetRTCPMultiplexing()

void qrtplib::RTPUDPTransmissionParams::SetRTCPMultiplexing ( bool  f)
inline

Enables or disables multiplexing RTCP traffic over the RTP channel, so that only a single port is used.

Definition at line 127 of file rtpudptransmitter.h.

Referenced by RTPSink::RTPSink().

128  {
129  m_rtcpmux = f;
130  }
+ Here is the caller graph for this function:

◆ SetRTCPReceiveBufferSize()

void qrtplib::RTPUDPTransmissionParams::SetRTCPReceiveBufferSize ( int  s)
inline

Sets the RTCP socket's receive buffer size.

Definition at line 121 of file rtpudptransmitter.h.

122  {
123  m_rtcprecvbufsz = s;
124  }

◆ SetRTCPSendBufferSize()

void qrtplib::RTPUDPTransmissionParams::SetRTCPSendBufferSize ( int  s)
inline

Sets the RTCP socket's send buffer size.

Definition at line 115 of file rtpudptransmitter.h.

116  {
117  m_rtcpsendbufsz = s;
118  }

◆ SetRTPReceiveBufferSize()

void qrtplib::RTPUDPTransmissionParams::SetRTPReceiveBufferSize ( int  s)
inline

Sets the RTP socket's receive buffer size.

Definition at line 109 of file rtpudptransmitter.h.

110  {
111  m_rtprecvbufsz = s;
112  }

◆ SetRTPSendBufferSize()

void qrtplib::RTPUDPTransmissionParams::SetRTPSendBufferSize ( int  s)
inline

Sets the RTP socket's send buffer size.

Definition at line 103 of file rtpudptransmitter.h.

104  {
105  m_rtpsendbufsz = s;
106  }

◆ SetUseExistingSockets()

void qrtplib::RTPUDPTransmissionParams::SetUseExistingSockets ( QUdpSocket *  rtpsocket,
QUdpSocket *  rtcpsocket 
)
inline

Use sockets that have already been created, no checks on port numbers will be done, and no buffer sizes will be set; you'll need to close the sockets yourself when done, it will not be done automatically.

Definition at line 148 of file rtpudptransmitter.h.

Referenced by RTPSink::RTPSink().

149  {
150  m_rtpsock = rtpsocket;
151  m_rtcpsock = rtcpsocket;
152  m_useexistingsockets = true;
153  }
+ Here is the caller graph for this function:

Member Data Documentation

◆ m_allowoddportbase

bool qrtplib::RTPUDPTransmissionParams::m_allowoddportbase
private

Definition at line 218 of file rtpudptransmitter.h.

Referenced by RTPUDPTransmissionParams().

◆ m_bindAddress

QHostAddress qrtplib::RTPUDPTransmissionParams::m_bindAddress
private

Definition at line 212 of file rtpudptransmitter.h.

◆ m_forcedrtcpport

uint16_t qrtplib::RTPUDPTransmissionParams::m_forcedrtcpport
private

Definition at line 219 of file rtpudptransmitter.h.

Referenced by RTPUDPTransmissionParams().

◆ m_mcastInterface

QNetworkInterface qrtplib::RTPUDPTransmissionParams::m_mcastInterface
private

Definition at line 213 of file rtpudptransmitter.h.

◆ m_portbase

uint16_t qrtplib::RTPUDPTransmissionParams::m_portbase
private

Definition at line 214 of file rtpudptransmitter.h.

Referenced by RTPUDPTransmissionParams().

◆ m_rtcpmux

bool qrtplib::RTPUDPTransmissionParams::m_rtcpmux
private

Definition at line 217 of file rtpudptransmitter.h.

Referenced by RTPUDPTransmissionParams().

◆ m_rtcprecvbufsz

int qrtplib::RTPUDPTransmissionParams::m_rtcprecvbufsz
private

Definition at line 216 of file rtpudptransmitter.h.

Referenced by RTPUDPTransmissionParams().

◆ m_rtcpsendbufsz

int qrtplib::RTPUDPTransmissionParams::m_rtcpsendbufsz
private

Definition at line 216 of file rtpudptransmitter.h.

Referenced by RTPUDPTransmissionParams().

◆ m_rtcpsock

QUdpSocket * qrtplib::RTPUDPTransmissionParams::m_rtcpsock
private

Definition at line 221 of file rtpudptransmitter.h.

Referenced by RTPUDPTransmissionParams().

◆ m_rtprecvbufsz

int qrtplib::RTPUDPTransmissionParams::m_rtprecvbufsz
private

Definition at line 215 of file rtpudptransmitter.h.

Referenced by RTPUDPTransmissionParams().

◆ m_rtpsendbufsz

int qrtplib::RTPUDPTransmissionParams::m_rtpsendbufsz
private

Definition at line 215 of file rtpudptransmitter.h.

Referenced by RTPUDPTransmissionParams().

◆ m_rtpsock

QUdpSocket* qrtplib::RTPUDPTransmissionParams::m_rtpsock
private

Definition at line 221 of file rtpudptransmitter.h.

Referenced by RTPUDPTransmissionParams().

◆ m_useexistingsockets

bool qrtplib::RTPUDPTransmissionParams::m_useexistingsockets
private

Definition at line 222 of file rtpudptransmitter.h.

Referenced by RTPUDPTransmissionParams().


The documentation for this class was generated from the following file: