AVPQueue3
This class, an rtp/rtcp queue, adds audio/video profile (avp) specific methods to the generic rtcp service queue (queuertcpmanager).
Usage
Inherits QueueRTCPManager.
Inherited by
TRTPSessionBase<
DualRTPUDPIPv4Channel,
DualRTPUDPIPv4Channel,
AVPQueue
>,
and
TRTPSessionBase<
RTPDataChannel,
RTCPChannel,
ServiceQueue
>.
Public Member Functions
void setControlBandwidth
(float
fraction)
Public Member
Functions
inherited
from
QueueRTCPManager
RTCPSenderInfo
*
getMRSenderInfo
(SyncSource
&src)
microtimeout_t getEnd2EndDelay
()
const
void setSendersControlFraction
(float
fraction)
Set output
queue
CryptoContext.
void
removeOutQueueCryptoContextCtrl
(CryptoContextCtrl
*cc)
Remove output
queue
CryptoContext.
CryptoContextCtrl
*
getOutQueueCryptoContextCtrl
(uint32
ssrc)
Get an
output
queue
CryptoContext
identified
by
SSRC.
void
setInQueueCryptoContextCtrl
(CryptoContextCtrl
*cc)
Set input
queue
CryptoContext.
void
removeInQueueCryptoContextCtrl
(CryptoContextCtrl
*cc)
Remove input
queue
CryptoContext.
CryptoContextCtrl
*
getInQueueCryptoContextCtrl
(uint32
ssrc)
Get an
input
queue
CryptoContext
identified
by
SSRC.
Public Member
Functions
inherited
from
RTPDataQueue
void
setTypeOfService
(Tos
tos)
uint32 getSessionBandwidth
()
const
void setTimeclock
()
Public Member
Functions
inherited
from
IncomingDataQueue
SyncSourcesIterator
begin
()
SyncSourcesIterator end
()
uint8 getMinValidPacketSequence
()
const
uint16 getDefaultMaxPacketMisorder
()
const
uint16 getMaxPacketMisorder
()
const
void setMaxPacketDropout
(uint16
packets)
uint16 getMaxPacketDropout
()
const
void setInQueueCryptoContext
(CryptoContext
*cc)
Set input
queue
CryptoContext.
void
removeInQueueCryptoContext
(CryptoContext
*cc)
Remove input
queue
CryptoContext.
CryptoContext
*
getInQueueCryptoContext
(uint32
ssrc)
Get an
input
queue
CryptoContext
identified
by
SSRC.
Public Member
Functions
inherited
from
IncomingDataQueueBase
size_t
getDefaultMaxRecvPacketSize
()
const
size_t getMaxRecvPacketSize
()
const
void setMaxRecvPacketSize
(size_t
maxsize)
Public Member
Functions
inherited
from
RTPQueueBase
bool
setPayloadFormat
(const
PayloadFormat
&pf)
uint32 getCurrentRTPClockRate
()
const
timeval getInitialTime
()
const
Public Member
Functions
inherited
from
OutgoingDataQueue
bool
addDestination
(const
InetHostAddress
&ia,
tpport_t
dataPort=DefaultRTPDataPort,
tpport_t
controlPort=0)
bool addDestination
(const
InetMcastAddress
&ia,
tpport_t
dataPort=DefaultRTPDataPort,
tpport_t
controlPort=0)
bool forgetDestination
(const
InetHostAddress
&ia,
tpport_t
dataPort=DefaultRTPDataPort,
tpport_t
controlPort=0)
bool forgetDestination
(const
InetMcastAddress
&ia,
tpport_t
dataPort=DefaultRTPDataPort,
tpport_t
controlPort=0)
void addContributor
(uint32
csrc)
void setSchedulingTimeout
(microtimeout_t
to)
void setExpireTimeout
(microtimeout_t
to)
uint32 getSendPacketCount
()
const
Set output
queue
CryptoContext.
void
removeOutQueueCryptoContext
(CryptoContext
*cc)
Remove output
queue
CryptoContext.
CryptoContext
*
getOutQueueCryptoContext
(uint32
ssrc)
Get an
output
queue
CryptoContext
identified
by
SSRC.
Public Member
Functions
inherited
from
OutgoingDataQueueBase
size_t
getDefaultMaxSendSegmentSize
()
void setMaxSendSegmentSize
(size_t
size)
Protected Member Functions
AVPQueue (uint32
size=RTPDataQueue::defaultMembersHashSize,
RTPApplication
&app=defaultApplication())
Protected Member
Functions
inherited
from
QueueRTCPManager
QueueRTCPManager
(uint32
size=RTPDataQueue::defaultMembersHashSize,
RTPApplication
&app=defaultApplication())
virtual ~QueueRTCPManager
()
const RTPApplication
&
getApplication
()
void setControlBandwidth
(float
fraction)
float getControlBandwidth
()
const
void controlTransmissionService
()
Build and
send
RTCP
packets
following
timing
rules
(including
the
'timer
reconsideration'
algorithm).
void
controlReceptionService
()
virtual void
onGotSR
(SyncSource
&source,
SendReport
&SR,
uint8
blocks)
Plug-in for
processing
(acquire
information
carried
in)
an
incoming
RTCP
Sender
Report.
virtual
void
onGotRR
(SyncSource
&source,
RecvReport
&RR,
uint8
blocks)
Plug-in for
processing
(acquire
information
carried
in)
an
incoming
RTCP
Receiver
Report.
bool
onGotSDES
(SyncSource
&source,
RTCPPacket
&pkt)
virtual bool
onGotSDESChunk
(SyncSource
&source,
SDESChunk
&chunk,
size_t
len)
uint32 getLastSendPacketCount
()
const
uint32 getPrevMembersCount
()
const
size_t dispatchBYE
(const
std::string
&reason)
Protected Member
Functions
inherited
from
RTPDataQueue
RTPDataQueue
(uint32
size=defaultMembersHashSize)
Constructor. RTPDataQueue
(uint32
*ssrc,
uint32
size=defaultMembersHashSize)
void endQueue
()
Protected Member
Functions
inherited
from
IncomingDataQueue
IncomingDataQueue
(uint32
size)
virtual ~IncomingDataQueue
()
bool checkSSRCInIncomingRTPPkt
(SyncSourceLink
&sourceLink,
bool
is_new,
InetAddress
&na,
tpport_t
tp)
Set the
number
of
RTCP
intervals
that
the
stack
will
wait
to
change
the
state
of
a
source
from
stateActive
to
stateInactive,
or
to
delete
the
source
after
being
in
stateInactive.
virtual
size_t
takeInDataPacket
()
virtual void
onNewSyncSource
(const
SyncSource
&)
Protected Member
Functions
inherited
from
IncomingDataQueueBase
IncomingDataQueueBase
()
virtual ~IncomingDataQueueBase
()
Protected Member
Functions
inherited
from
RTPQueueBase
RTPQueueBase
(uint32
*ssrc=NULL)
void setLocalSSRC
(uint32
ssrc)
uint32 getLocalSSRCNetwork
()
const
virtual ~RTPQueueBase
()
Protected Member
Functions
inherited
from
MembershipBookkeeping
MembershipBookkeeping
(uint32
initialSize=defaultMembersHashSize)
bool isMine
(const
SyncSource
&source)
const
Remove the
description
of
the
source
identified
by
ssrc
SyncSourceLink
*
getFirst
()
SyncSourceLink *
getLast
()
uint32 getMembersCount
()
void setMembersCount
(uint32
n)
uint32 getSendersCount
()
size_t getDefaultMembersHashSize
()
Protected Member
Functions
inherited
from
SyncSourceHandler
SyncSourceHandler
()
virtual ~SyncSourceHandler
()
void *
getLink
(const
SyncSource
&source)
const
void setParticipant
(SyncSource
&source,
Participant
&p)
void setState
(SyncSource
&source,
SyncSource::State
ns)
void setSender
(SyncSource
&source,
bool
active)
void setDataTransportPort
(SyncSource
&source,
tpport_t
p)
void setControlTransportPort
(SyncSource
&source,
tpport_t
p)
void setNetworkAddress
(SyncSource
&source,
InetAddress
addr)
Protected Member
Functions
inherited
from
ParticipantHandler
ParticipantHandler
()
virtual ~ParticipantHandler
()
void setPRIVPrefix
(Participant
*part,
const
std::string
val)
Protected Member
Functions
inherited
from
ApplicationHandler
ApplicationHandler
()
virtual ~ApplicationHandler
()
void addParticipant
(RTPApplication
&app,
Participant
&part)
void removeParticipant
(RTPApplication
&app,
RTPApplication::ParticipantLink
*pl)
Protected Member
Functions
inherited
from
ConflictHandler
ConflictHandler
()
virtual ~ConflictHandler
()
void updateConflict
(ConflictingTransportAddress
&ca)
Protected Member
Functions
inherited
from
OutgoingDataQueue
OutgoingDataQueue
()
virtual ~OutgoingDataQueue
()
void dispatchImmediate
(OutgoingRTPPkt
*packet)
For thoses
cases
in
which
the
application
requires
a
method
to
set
the
sequence
number
for
the
outgoing
stream
(such
as
for
implementing
the
RTSP
PLAY
command).
uint32
getCurrentSeqNum
(void)
void setInitialTimestamp
(uint32
ts)
uint32 getInitialTimestamp
()
void purgeOutgoingQueue
()
virtual void
setControlPeer
(const
InetAddress
&host,
tpport_t
port)
Protected Member
Functions
inherited
from
OutgoingDataQueueBase
OutgoingDataQueueBase
()
virtual ~OutgoingDataQueueBase
()
Protected Member
Functions
inherited
from
DestinationListHandler
void
writeLockDestinationList
()
const
bool isSingleDestination
()
const
void lockDestinationList
()
const
void unlockDestinationList
()
const
Protected Member
Functions
inherited
from
RTCPCompoundHandler
RTCPCompoundHandler
(uint16
mtu=defaultPathMTU)
bool checkCompoundRTCPHeader
(size_t
len)
Perform RTCP
compound
packet
header
validity
check
as
specified
in
draft-ietv-avt-rtp-new.
void
setPathMTU
(uint16
mtu)
uint16 getPathMTU
()
Additional Inherited Members
Public Types
inherited
from
RTPDataQueue
enum
Tos
tosBestEffort,
tosEnhanced
rtp.h cc++/rtp.h
Static Public
Member
Functions
inherited
from
IncomingDataQueue
static
size_t
getDefaultMembersSize
()
Protected Types
inherited
from
RTCPCompoundHandler
enum
defaultPathMTU
=
1500
Protected Attributes
inherited
from
IncomingDataQueue
ThreadLock
recvLock
IncomingRTPPktLink *
recvFirst
IncomingRTPPktLink *
recvLast
uint8 minValidPacketSequence
uint16 maxPacketMisorder
uint16 maxPacketDropout
uint8 sourceExpirationPeriod
Mutex cryptoMutex
Protected Attributes
inherited
from
ConflictHandler
ConflictingTransportAddress
*
firstConflict
ConflictingTransportAddress *
lastConflict
Protected Attributes
inherited
from
OutgoingDataQueue
Mutex
cryptoMutex
Protected Attributes
inherited
from
DestinationListHandler
std::list<
TransportAddress
*
>
destList
Protected Attributes
inherited
from
RTCPCompoundHandler
unsigned
char
*
rtcpSendBuffer
unsigned char
*
rtcpRecvBuffer
Static Protected
Attributes
inherited
from
IncomingDataQueue
static
const
uint8
defaultMinValidPacketSequence
static const
uint16
defaultMaxPacketMisorder
static const
uint16
defaultMaxPacketDropout
static const
size_t
defaultMembersSize
Static Protected
Attributes
inherited
from
MembershipBookkeeping
static
const
size_t
defaultMembersHashSize
static const
uint32
SEQNUMMOD
Detailed Description
This class, an RTP/RTCP queue, adds audio/video profile (AVP) specific methods to the generic RTCP service queue (QueueRTCPManager).
Author
Federico Montesino Pouzols [email protected]
Constructor & Destructor Documentation
AVPQueue::AVPQueue (uint32 size = RTPDataQueue::defaultMembersHashSize, RTPApplication & app = defaultApplication()) [inline], [protected]
AVPQueue::AVPQueue (uint32 ssrc, uint32 size = RTPDataQueue::defaultMembersHashSize, RTPApplication & app = defaultApplication()) [inline], [protected]
Local SSRC is given instead of computed by the queue.
virtual AVPQueue::~AVPQueue () [inline], [protected], [virtual]
Member Function Documentation
float AVPQueue::getControlBandwidth () const [inline]
void AVPQueue::setControlBandwidth (float fraction) [inline]
Specify the bandwith available for control (RTCP) packets. This method sets the global control bandwidth for both sender and receiver reports. As recommended in RFC 1890, 1/4 of the total control bandwidth is dedicated to senders, whereas 3/4 are dedicated to receivers.
Parameters
fraction fraction of the session bandwidth, between 0 and 1
Note
If this method is not called, it is assumed that the control bandwidth is equal to 5% of the session bandwidth. Note also that the RFC RECOMMENDS the 5%.
History
- Debian 13 (Trixie): the text shown here
- Debian 12 (Bookworm) to Debian 10 (Buster)
- Debian 9 (Stretch)
- Debian 8 (Jessie)
- Debian 7 (Wheezy)
- Debian 6.0 (Squeeze)
- Debian 5.0 (Lenny)
- Debian 4.0 (Etch)
- Debian 3.1 (Sarge)