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

#include <rtpsessionsources.h>

+ Inheritance diagram for qrtplib::RTPSessionSources:
+ Collaboration diagram for qrtplib::RTPSessionSources:

Public Member Functions

 RTPSessionSources (RTPSession &sess)
 
 ~RTPSessionSources ()
 
void ClearOwnCollisionFlag ()
 
bool DetectedOwnCollision () const
 
- Public Member Functions inherited from qrtplib::RTPSources
 RTPSources ()
 
virtual ~RTPSources ()
 
void Clear ()
 
int CreateOwnSSRC (uint32_t ssrc)
 
int DeleteOwnSSRC ()
 
void SentRTPPacket ()
 
int ProcessRawPacket (RTPRawPacket *rawpack, RTPTransmitter *trans, bool acceptownpackets)
 
int ProcessRawPacket (RTPRawPacket *rawpack, RTPTransmitter *trans[], int numtrans, bool acceptownpackets)
 
int ProcessRTPPacket (RTPPacket *rtppack, const RTPTime &receivetime, const RTPAddress *senderaddress, bool *stored)
 
int ProcessRTCPCompoundPacket (RTCPCompoundPacket *rtcpcomppack, const RTPTime &receivetime, const RTPAddress *senderaddress)
 
int ProcessRTCPSenderInfo (uint32_t ssrc, const RTPNTPTime &ntptime, uint32_t rtptime, uint32_t packetcount, uint32_t octetcount, const RTPTime &receivetime, const RTPAddress *senderaddress)
 
int ProcessRTCPReportBlock (uint32_t ssrc, uint8_t fractionlost, int32_t lostpackets, uint32_t exthighseqnr, uint32_t jitter, uint32_t lsr, uint32_t dlsr, const RTPTime &receivetime, const RTPAddress *senderaddress)
 
int ProcessSDESNormalItem (uint32_t ssrc, RTCPSDESPacket::ItemType t, std::size_t itemlength, const void *itemdata, const RTPTime &receivetime, const RTPAddress *senderaddress)
 
int ProcessSDESPrivateItem (uint32_t ssrc, std::size_t prefixlen, const void *prefixdata, std::size_t valuelen, const void *valuedata, const RTPTime &receivetime, const RTPAddress *senderaddress)
 
int ProcessBYE (uint32_t ssrc, std::size_t reasonlength, const void *reasondata, const RTPTime &receivetime, const RTPAddress *senderaddress)
 
int UpdateReceiveTime (uint32_t ssrc, const RTPTime &receivetime, const RTPAddress *senderaddress)
 
bool GotoFirstSource ()
 
bool GotoNextSource ()
 
bool GotoPreviousSource ()
 
bool GotoFirstSourceWithData ()
 
bool GotoNextSourceWithData ()
 
bool GotoPreviousSourceWithData ()
 
RTPSourceDataGetCurrentSourceInfo ()
 
RTPSourceDataGetSourceInfo (uint32_t ssrc)
 
RTPPacketGetNextPacket ()
 
bool GotEntry (uint32_t ssrc)
 
RTPSourceDataGetOwnSourceInfo ()
 
void Timeout (const RTPTime &curtime, const RTPTime &timeoutdelay)
 
void SenderTimeout (const RTPTime &curtime, const RTPTime &timeoutdelay)
 
void BYETimeout (const RTPTime &curtime, const RTPTime &timeoutdelay)
 
void NoteTimeout (const RTPTime &curtime, const RTPTime &timeoutdelay)
 
void MultipleTimeouts (const RTPTime &curtime, const RTPTime &sendertimeout, const RTPTime &byetimeout, const RTPTime &generaltimeout, const RTPTime &notetimeout)
 
int GetSenderCount () const
 
int GetTotalCount () const
 
int GetActiveMemberCount () const
 

Private Member Functions

void OnRTPPacket (RTPPacket *pack, const RTPTime &receivetime, const RTPAddress *senderaddress)
 
void OnRTCPCompoundPacket (RTCPCompoundPacket *pack, const RTPTime &receivetime, const RTPAddress *senderaddress)
 
void OnSSRCCollision (RTPSourceData *srcdat, const RTPAddress *senderaddress, bool isrtp)
 
void OnCNAMECollision (RTPSourceData *srcdat, const RTPAddress *senderaddress, const uint8_t *cname, std::size_t cnamelength)
 
void OnNewSource (RTPSourceData *srcdat)
 
void OnRemoveSource (RTPSourceData *srcdat)
 
void OnTimeout (RTPSourceData *srcdat)
 
void OnBYETimeout (RTPSourceData *srcdat)
 
void OnBYEPacket (RTPSourceData *srcdat)
 
void OnAPPPacket (RTCPAPPPacket *apppacket, const RTPTime &receivetime, const RTPAddress *senderaddress)
 
void OnUnknownPacketType (RTCPPacket *rtcppack, const RTPTime &receivetime, const RTPAddress *senderaddress)
 
void OnUnknownPacketFormat (RTCPPacket *rtcppack, const RTPTime &receivetime, const RTPAddress *senderaddress)
 
void OnNoteTimeout (RTPSourceData *srcdat)
 
void OnValidatedRTPPacket (RTPSourceData *srcdat, RTPPacket *rtppack, bool isonprobation, bool *ispackethandled)
 
void OnRTCPSenderReport (RTPSourceData *srcdat)
 
void OnRTCPReceiverReport (RTPSourceData *srcdat)
 
void OnRTCPSDESItem (RTPSourceData *srcdat, RTCPSDESPacket::ItemType t, const void *itemdata, std::size_t itemlength)
 
void OnRTCPSDESPrivateItem (RTPSourceData *srcdat, const void *prefixdata, std::size_t prefixlen, const void *valuedata, std::size_t valuelen)
 

Private Attributes

RTPSessionrtpsession
 
bool owncollision
 

Additional Inherited Members

- Public Types inherited from qrtplib::RTPSources
enum  ProbationType { NoProbation, ProbationDiscard, ProbationStore }
 

Detailed Description

Definition at line 51 of file rtpsessionsources.h.

Constructor & Destructor Documentation

◆ RTPSessionSources()

qrtplib::RTPSessionSources::RTPSessionSources ( RTPSession sess)
inline

Definition at line 54 of file rtpsessionsources.h.

54  :
55  rtpsession(sess)
56  {
57  owncollision = false;
58  }

◆ ~RTPSessionSources()

qrtplib::RTPSessionSources::~RTPSessionSources ( )
inline

Definition at line 59 of file rtpsessionsources.h.

60  {
61  }

Member Function Documentation

◆ ClearOwnCollisionFlag()

void qrtplib::RTPSessionSources::ClearOwnCollisionFlag ( )
inline

Definition at line 62 of file rtpsessionsources.h.

Referenced by qrtplib::RTPSession::ProcessPolledData().

63  {
64  owncollision = false;
65  }
+ Here is the caller graph for this function:

◆ DetectedOwnCollision()

bool qrtplib::RTPSessionSources::DetectedOwnCollision ( ) const
inline

Definition at line 66 of file rtpsessionsources.h.

Referenced by qrtplib::RTPSession::ProcessPolledData().

67  {
68  return owncollision;
69  }
+ Here is the caller graph for this function:

◆ OnAPPPacket()

void qrtplib::RTPSessionSources::OnAPPPacket ( RTCPAPPPacket apppacket,
const RTPTime receivetime,
const RTPAddress senderaddress 
)
privatevirtual

Is called when an RTCP APP packet apppacket has been received at time receivetime from address senderaddress.

Reimplemented from qrtplib::RTPSources.

Definition at line 91 of file rtpsessionsources.cpp.

References qrtplib::RTPSession::OnAPPPacket(), and rtpsession.

92 {
93  rtpsession.OnAPPPacket(apppacket, receivetime, senderaddress);
94 }
virtual void OnAPPPacket(RTCPAPPPacket *apppacket, const RTPTime &receivetime, const RTPAddress *senderaddress)
Definition: rtpsession.h:611
+ Here is the call graph for this function:

◆ OnBYEPacket()

void qrtplib::RTPSessionSources::OnBYEPacket ( RTPSourceData srcdat)
privatevirtual

Is called when a BYE packet has been processed for source srcdat.

Reimplemented from qrtplib::RTPSources.

Definition at line 85 of file rtpsessionsources.cpp.

References qrtplib::RTCPScheduler::ActiveMemberDecrease(), qrtplib::RTPSession::OnBYEPacket(), qrtplib::RTPSession::rtcpsched, and rtpsession.

86 {
88  rtpsession.OnBYEPacket(srcdat);
89 }
RTCPScheduler rtcpsched
Definition: rtpsession.h:573
virtual void OnBYEPacket(RTPSourceData *srcdat)
Definition: rtpsession.h:639
+ Here is the call graph for this function:

◆ OnBYETimeout()

void qrtplib::RTPSessionSources::OnBYETimeout ( RTPSourceData srcdat)
privatevirtual

Is called when participant srcdat is timed after having sent a BYE packet.

Reimplemented from qrtplib::RTPSources.

Definition at line 80 of file rtpsessionsources.cpp.

References qrtplib::RTPSession::OnBYETimeout(), and rtpsession.

81 {
82  rtpsession.OnBYETimeout(srcdat);
83 }
virtual void OnBYETimeout(RTPSourceData *srcdat)
Definition: rtpsession.h:608
+ Here is the call graph for this function:

◆ OnCNAMECollision()

void qrtplib::RTPSessionSources::OnCNAMECollision ( RTPSourceData srcdat,
const RTPAddress senderaddress,
const uint8_t cname,
std::size_t  cnamelength 
)
privatevirtual

Is called when another CNAME was received than the one already present for source srcdat.

Reimplemented from qrtplib::RTPSources.

Definition at line 59 of file rtpsessionsources.cpp.

References qrtplib::RTPSession::OnCNAMECollision(), and rtpsession.

60 {
61  rtpsession.OnCNAMECollision(srcdat, senderaddress, cname, cnamelength);
62 }
virtual void OnCNAMECollision(RTPSourceData *srcdat, const RTPAddress *senderaddress, const uint8_t *cname, std::size_t cnamelength)
Definition: rtpsession.h:596
+ Here is the call graph for this function:

◆ OnNewSource()

void qrtplib::RTPSessionSources::OnNewSource ( RTPSourceData srcdat)
privatevirtual

Is called when a new entry srcdat is added to the source table.

Reimplemented from qrtplib::RTPSources.

Definition at line 64 of file rtpsessionsources.cpp.

References qrtplib::RTPSession::OnNewSource(), and rtpsession.

65 {
66  rtpsession.OnNewSource(srcdat);
67 }
virtual void OnNewSource(RTPSourceData *srcdat)
Definition: rtpsession.h:599
+ Here is the call graph for this function:

◆ OnNoteTimeout()

void qrtplib::RTPSessionSources::OnNoteTimeout ( RTPSourceData srcdat)
privatevirtual

Is called when the SDES NOTE item for source srcdat has been timed out.

Reimplemented from qrtplib::RTPSources.

Definition at line 106 of file rtpsessionsources.cpp.

References qrtplib::RTPSession::OnNoteTimeout(), and rtpsession.

107 {
108  rtpsession.OnNoteTimeout(srcdat);
109 }
virtual void OnNoteTimeout(RTPSourceData *srcdat)
Definition: rtpsession.h:620
+ Here is the call graph for this function:

◆ OnRemoveSource()

void qrtplib::RTPSessionSources::OnRemoveSource ( RTPSourceData srcdat)
privatevirtual

Is called when the entry srcdat is about to be deleted from the source table.

Reimplemented from qrtplib::RTPSources.

Definition at line 69 of file rtpsessionsources.cpp.

References qrtplib::RTPSession::OnRemoveSource(), and rtpsession.

70 {
71  rtpsession.OnRemoveSource(srcdat);
72 }
virtual void OnRemoveSource(RTPSourceData *srcdat)
Definition: rtpsession.h:602
+ Here is the call graph for this function:

◆ OnRTCPCompoundPacket()

void qrtplib::RTPSessionSources::OnRTCPCompoundPacket ( RTCPCompoundPacket pack,
const RTPTime receivetime,
const RTPAddress senderaddress 
)
privatevirtual

Is called when an RTCP compound packet is about to be processed.

Reimplemented from qrtplib::RTPSources.

Definition at line 45 of file rtpsessionsources.cpp.

References qrtplib::RTCPScheduler::AnalyseIncoming(), qrtplib::RTPSession::OnRTCPCompoundPacket(), qrtplib::RTPSession::rtcpsched, and rtpsession.

46 {
47  if (senderaddress != 0) // don't analyse own RTCP packets again (they're already analysed on their way out)
49  rtpsession.OnRTCPCompoundPacket(pack, receivetime, senderaddress);
50 }
void AnalyseIncoming(RTCPCompoundPacket &rtcpcomppack)
virtual void OnRTCPCompoundPacket(RTCPCompoundPacket *pack, const RTPTime &receivetime, const RTPAddress *senderaddress)
Definition: rtpsession.h:590
RTCPScheduler rtcpsched
Definition: rtpsession.h:573
+ Here is the call graph for this function:

◆ OnRTCPReceiverReport()

void qrtplib::RTPSessionSources::OnRTCPReceiverReport ( RTPSourceData srcdat)
privatevirtual

Is called when an RTCP receiver report has been processed for this source.

Reimplemented from qrtplib::RTPSources.

Definition at line 121 of file rtpsessionsources.cpp.

References qrtplib::RTPSession::OnRTCPReceiverReport(), and rtpsession.

122 {
124 }
virtual void OnRTCPReceiverReport(RTPSourceData *srcdat)
Definition: rtpsession.h:626
+ Here is the call graph for this function:

◆ OnRTCPSDESItem()

void qrtplib::RTPSessionSources::OnRTCPSDESItem ( RTPSourceData srcdat,
RTCPSDESPacket::ItemType  t,
const void *  itemdata,
std::size_t  itemlength 
)
privatevirtual

Is called when a specific SDES item was received for this source.

Reimplemented from qrtplib::RTPSources.

Definition at line 126 of file rtpsessionsources.cpp.

References qrtplib::RTPSession::OnRTCPSDESItem(), and rtpsession.

127 {
128  rtpsession.OnRTCPSDESItem(srcdat, t, itemdata, itemlength);
129 }
virtual void OnRTCPSDESItem(RTPSourceData *srcdat, RTCPSDESPacket::ItemType t, const void *itemdata, std::size_t itemlength)
Definition: rtpsession.h:629
+ Here is the call graph for this function:

◆ OnRTCPSDESPrivateItem()

void qrtplib::RTPSessionSources::OnRTCPSDESPrivateItem ( RTPSourceData srcdat,
const void *  prefixdata,
std::size_t  prefixlen,
const void *  valuedata,
std::size_t  valuelen 
)
privatevirtual

Is called when a specific SDES item of 'private' type was received for this source.

Reimplemented from qrtplib::RTPSources.

Definition at line 132 of file rtpsessionsources.cpp.

References qrtplib::RTPSession::OnRTCPSDESPrivateItem(), and rtpsession.

133 {
134  rtpsession.OnRTCPSDESPrivateItem(srcdat, prefixdata, prefixlen, valuedata, valuelen);
135 }
virtual void OnRTCPSDESPrivateItem(RTPSourceData *srcdat, const void *prefixdata, std::size_t prefixlen, const void *valuedata, std::size_t valuelen)
Definition: rtpsession.h:634
+ Here is the call graph for this function:

◆ OnRTCPSenderReport()

void qrtplib::RTPSessionSources::OnRTCPSenderReport ( RTPSourceData srcdat)
privatevirtual

Is called when an RTCP sender report has been processed for this source.

Reimplemented from qrtplib::RTPSources.

Definition at line 116 of file rtpsessionsources.cpp.

References qrtplib::RTPSession::OnRTCPSenderReport(), and rtpsession.

117 {
119 }
virtual void OnRTCPSenderReport(RTPSourceData *srcdat)
Definition: rtpsession.h:623
+ Here is the call graph for this function:

◆ OnRTPPacket()

void qrtplib::RTPSessionSources::OnRTPPacket ( RTPPacket pack,
const RTPTime receivetime,
const RTPAddress senderaddress 
)
privatevirtual

Is called when an RTP packet is about to be processed.

Reimplemented from qrtplib::RTPSources.

Definition at line 40 of file rtpsessionsources.cpp.

References qrtplib::RTPSession::OnRTPPacket(), and rtpsession.

41 {
42  rtpsession.OnRTPPacket(pack, receivetime, senderaddress);
43 }
virtual void OnRTPPacket(RTPPacket *pack, const RTPTime &receivetime, const RTPAddress *senderaddress)
Definition: rtpsession.h:587
+ Here is the call graph for this function:

◆ OnSSRCCollision()

void qrtplib::RTPSessionSources::OnSSRCCollision ( RTPSourceData srcdat,
const RTPAddress senderaddress,
bool  isrtp 
)
privatevirtual

Is called when an SSRC collision was detected. Is called when an SSRC collision was detected. The instance srcdat is the one present in the table, the address senderaddress is the one that collided with one of the addresses and isrtp indicates against which address of srcdat the check failed.

Reimplemented from qrtplib::RTPSources.

Definition at line 52 of file rtpsessionsources.cpp.

References qrtplib::RTPSourceData::IsOwnSSRC(), qrtplib::RTPSession::OnSSRCCollision(), owncollision, and rtpsession.

53 {
54  if (srcdat->IsOwnSSRC())
55  owncollision = true;
56  rtpsession.OnSSRCCollision(srcdat, senderaddress, isrtp);
57 }
virtual void OnSSRCCollision(RTPSourceData *srcdat, const RTPAddress *senderaddress, bool isrtp)
Definition: rtpsession.h:593
+ Here is the call graph for this function:

◆ OnTimeout()

void qrtplib::RTPSessionSources::OnTimeout ( RTPSourceData srcdat)
privatevirtual

Is called when participant srcdat is timed out.

Reimplemented from qrtplib::RTPSources.

Definition at line 74 of file rtpsessionsources.cpp.

References qrtplib::RTCPScheduler::ActiveMemberDecrease(), qrtplib::RTPSession::OnTimeout(), qrtplib::RTPSession::rtcpsched, and rtpsession.

75 {
77  rtpsession.OnTimeout(srcdat);
78 }
RTCPScheduler rtcpsched
Definition: rtpsession.h:573
virtual void OnTimeout(RTPSourceData *srcdat)
Definition: rtpsession.h:605
+ Here is the call graph for this function:

◆ OnUnknownPacketFormat()

void qrtplib::RTPSessionSources::OnUnknownPacketFormat ( RTCPPacket rtcppack,
const RTPTime receivetime,
const RTPAddress senderaddress 
)
privatevirtual

Is called when an unknown packet format for a known packet type was detected.

Reimplemented from qrtplib::RTPSources.

Definition at line 101 of file rtpsessionsources.cpp.

References qrtplib::RTPSession::OnUnknownPacketFormat(), and rtpsession.

102 {
103  rtpsession.OnUnknownPacketFormat(rtcppack, receivetime, senderaddress);
104 }
virtual void OnUnknownPacketFormat(RTCPPacket *rtcppack, const RTPTime &receivetime, const RTPAddress *senderaddress)
Definition: rtpsession.h:617
+ Here is the call graph for this function:

◆ OnUnknownPacketType()

void qrtplib::RTPSessionSources::OnUnknownPacketType ( RTCPPacket rtcppack,
const RTPTime receivetime,
const RTPAddress senderaddress 
)
privatevirtual

Is called when an unknown RTCP packet type was detected.

Reimplemented from qrtplib::RTPSources.

Definition at line 96 of file rtpsessionsources.cpp.

References qrtplib::RTPSession::OnUnknownPacketType(), and rtpsession.

97 {
98  rtpsession.OnUnknownPacketType(rtcppack, receivetime, senderaddress);
99 }
virtual void OnUnknownPacketType(RTCPPacket *rtcppack, const RTPTime &receivetime, const RTPAddress *senderaddress)
Definition: rtpsession.h:614
+ Here is the call graph for this function:

◆ OnValidatedRTPPacket()

void qrtplib::RTPSessionSources::OnValidatedRTPPacket ( RTPSourceData srcdat,
RTPPacket rtppack,
bool  isonprobation,
bool *  ispackethandled 
)
privatevirtual

Allows you to use an RTP packet from the specified source directly. Allows you to use an RTP packet from the specified source directly. If ispackethandled is set to true, the packet will no longer be stored in this source's packet list.

Reimplemented from qrtplib::RTPSources.

Definition at line 111 of file rtpsessionsources.cpp.

References qrtplib::RTPSession::OnValidatedRTPPacket(), and rtpsession.

112 {
113  rtpsession.OnValidatedRTPPacket(srcdat, rtppack, isonprobation, ispackethandled);
114 }
virtual void OnValidatedRTPPacket(RTPSourceData *srcdat, RTPPacket *rtppack, bool isonprobation, bool *ispackethandled)
Definition: rtpsession.h:657
+ Here is the call graph for this function:

Member Data Documentation

◆ owncollision

bool qrtplib::RTPSessionSources::owncollision
private

Definition at line 93 of file rtpsessionsources.h.

Referenced by OnSSRCCollision().

◆ rtpsession

RTPSession& qrtplib::RTPSessionSources::rtpsession
private

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