Commit graph

208 commits

Author SHA1 Message Date
Olivier Crête b9ceafe5af rtpsession: Demux RTCP buffers from the RTP stream
If there are RTCP buffers in the RTP stream, process them as
RTCP. This way, we want receive streams following RFC 5761

https://bugzilla.gnome.org/show_bug.cgi?id=687657
2013-09-13 16:25:49 +02:00
Wim Taymans 28e5f90988 rtpbin: use PacketInfo for the sender
Avoid mapping the packet multiple times when sending RTP.
2013-09-13 14:34:28 +02:00
Wim Taymans a02c9473d8 rtpbin: store more in the PacketInfo
Store all info in the PacketInfo so that we can avoid mapping the packet
multiple times.
2013-09-13 14:34:28 +02:00
Wim Taymans e5c789abd6 session: store more in the PacketInfo structure 2013-09-13 14:34:28 +02:00
Wim Taymans 47662f9ca4 rtpbin: RTPArrivalStats -> RTPPacketInfo
Rename a structure because we are also going to use this for the sender
bits.
2013-09-13 14:34:28 +02:00
Wim Taymans f1106cde66 session: only update next check time when reconsidering
Don't update the next RTCP check time in all cases but only when we
reconsidered. This avoids delaying sending a full RTCP packet when we
are doing early feedback.
2013-08-27 09:55:52 +02:00
Wim Taymans 47065db0b6 session: add more debug 2013-08-27 09:55:52 +02:00
Wim Taymans 4b7bcc2ec1 rtsession: fix locking
We need to take the session lock when getting and manipulating the
source.
2013-08-26 11:50:27 +02:00
Wim Taymans 3f46527f75 rtpsession: add some more debug 2013-08-26 11:50:13 +02:00
Wim Taymans 5fe18ee432 session: add some docs 2013-08-19 22:04:49 +02:00
Wim Taymans 482dacfb54 session: handle NACK feedback and generate events
Handle and parse the feedback NACK packets and generate a Retransmission
event for each NACKed packet
2013-08-19 22:04:49 +02:00
Wim Taymans 48174164eb session: add NACK feedback in RTCP 2013-08-06 15:50:19 +02:00
Wim Taymans 50638b8106 session: handle Retransmission event and schedule NACK
Handle the retransmission event from downstream and use it to schedule a NACK
request.
2013-08-06 15:50:19 +02:00
Wim Taymans 0bddbd682d session: pass data to remove func
Pass the data to the remove function because we are going to deref it when there
is pli or fir.
2013-08-06 15:50:19 +02:00
Wim Taymans 3c82de59f9 session: use common send_rtcp method
Reuse the send_rtcp method that already asks for the current time when
requesting a keyframe.
2013-08-05 15:02:59 +02:00
Wim Taymans 3c14c6021c session: Don't use ClockTimeDiff for unsigned delays 2013-08-05 15:02:59 +02:00
Tim-Philipp Müller 7469cd3a4c rtpmanager: use generic marshaller 2013-08-04 11:03:07 +01:00
Wim Taymans 9613e481ad session: add FIR and PLI like other RTCP packets
Add the FIR and PLI packets like the other RTCP packet instead of from the
on-sending-rtcp default signal handler.
2013-08-03 00:33:24 +02:00
Wim Taymans 02359f9219 session: don't make buffer writable prematurely
There is no reason to make the SR buffer writable at this point. This is better
delayed until needed.
2013-07-26 22:31:41 +02:00
Wim Taymans 0261199fc4 session: ignore RTCP for inactive sources 2013-07-26 22:31:23 +02:00
Wim Taymans a4b4ca53c0 session: small cleanup 2013-07-26 22:25:17 +02:00
Wim Taymans e0abd2e9b5 session: handle partial RTCP report blocks
When we have more SSRCs to report than what fit in an RTCP packet, use a
generation counter to make sure all of them end up in a packet eventually.
2013-07-26 17:29:10 +02:00
Wim Taymans 6cce6fb04c session: create SSRC before doing session cleanup
Make the internal source before we do session cleanup
2013-07-26 17:29:10 +02:00
Wim Taymans 5b0298c63e session: reorganize the report block code 2013-07-26 17:29:10 +02:00
Wim Taymans 3c44cd7c83 session: refactor active and sender checks 2013-07-26 14:21:40 +02:00
Wim Taymans e952f7ba43 session: remove internal sources on timeout
When an internal source times out and becomes a receiver, remove it.
2013-07-26 12:18:01 +02:00
Wim Taymans e9e2fe3950 session: create an internal source for RTCP
When we need to do RTCP and we don't have an internal source yet,
make one.
2013-07-26 12:18:01 +02:00
Wim Taymans bd0709c15c session: remove old code to change SSRC
Remove code used to change the SSRC after a collision. We now send
a RECONFIGURE event upstream to make the upstream element change the SSRC.
2013-07-26 12:18:01 +02:00
Wim Taymans abc90da1dc session: delay allocation of internal source
Allocate the internal source when we receive a caps with the SSRC or when we see
a buffer with the SSRC.
2013-07-26 12:18:01 +02:00
Wim Taymans e0a1ce1291 session: generate reconfigure on collision
When we detect a collision, change the SSRC that we suggest upstream
and trigger RECONFIGURE. This should make upstream select a new SSRC.
2013-07-26 12:18:01 +02:00
Wim Taymans 495d43c089 session: produce RTCP for all internal sources
Loop over all the internal sources and produce RTCP. We also need
to queue the RTCP packets and send them when we are finished.
2013-07-26 12:18:00 +02:00
Wim Taymans 9505fd4150 session: deprecate internal source and ssrc properties
Deprecate the internal source and internal ssrc properties. There might
be more than one internal source.
2013-07-26 12:17:59 +02:00
Wim Taymans 3d6ee1fb5e session: internal sources don't use probation 2013-07-26 12:17:59 +02:00
Wim Taymans 0e53e9109e session: give caps to session
Let the session parse the caps and update its SSRC when needed.
2013-07-26 12:17:59 +02:00
Wim Taymans c06482a2cb session: make method to suggest available SSRC
Make a method to suggest the best available SSRC. This is the SSRC of the last
created internal source and is used to instruct upstream to produce this
SSRC.
2013-07-26 12:17:59 +02:00
Wim Taymans 33ce50e8b1 session: keep SDES and set on new internal sources
Keep track of the SDES ourselves and set it on all newly created
internal sources.
2013-07-26 12:17:59 +02:00
Wim Taymans 5652f02b76 session: make method to make internal sources
Add a method to obtain an internal source and use it to create
our internal source
2013-07-26 12:17:59 +02:00
Wim Taymans 7f83927c95 session: count internal sources and how many are senders 2013-07-26 12:17:58 +02:00
Wim Taymans 719343c206 rtpsession: separate BYE marking and scheduling
First mark sources with BYE and then schedule the BYE RTCP message.
2013-07-26 12:17:58 +02:00
Wim Taymans 391943ba82 session: get SSRC from RTCP packet itself
Get the SSRC from the RTCP packet instead.
2013-07-26 12:17:57 +02:00
Wim Taymans a3f75a17ef session: fix bandwidth calculation
We iterate over all sources and the internal one is also in the
hashtable so avoid adding it twice.
2013-07-26 12:17:57 +02:00
Wim Taymans 9eaef9d332 session: add some docs 2013-07-26 12:17:56 +02:00
Wim Taymans 2163355a47 session: Rearrange RTCP reporting a little
Make a function to generate an RTCP packet for a source, pass the source as a
parameter.
Move timeout of collisions to session cleanup phase.
2013-07-26 12:17:56 +02:00
Wim Taymans a3bf374351 session: move check for is_early around
Move the check for the early RTCP to where it is needed and used.
2013-07-26 12:17:56 +02:00
Wim Taymans b069db6a2e session: parse packet outside of the session lock 2013-07-26 12:17:56 +02:00
Wim Taymans 57c27ec319 session: do nicer checks for internal sources 2013-07-26 12:17:56 +02:00
Wim Taymans 93d07298ff session: let source keep track if it sent BYE 2013-07-26 12:17:56 +02:00
Wim Taymans 1d02496d15 source: also use the source for bye_reason
Store the BYE reason in our internal source object. Rename the methods on the
source object a little because now the BYE can be received in RTCP or
set when the session wants to send BYE.
2013-07-26 12:17:56 +02:00
Wim Taymans ddd071e54c session: configure sdes with structure only
Remove code to configure the SDES with methods and types, only
allow configuration with GstStructure
2013-07-26 12:17:55 +02:00
Wim Taymans 0060e1d45d session: refactor add and find source
Make functions to find and add a source to the hashtable.
2013-07-26 12:17:55 +02:00