After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 703560 - [PATCH] rtpbin: new event for informing downstream about synchronization
[PATCH] rtpbin: new event for informing downstream about synchronization
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-good
1.1.1
Other Linux
: Normal enhancement
: 1.1.3
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2013-07-03 16:57 UTC by Carlos Rafael Giani
Modified: 2013-07-23 04:35 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
patch which adds the custom downstream sync event (4.71 KB, patch)
2013-07-03 16:57 UTC, Carlos Rafael Giani
none Details | Review

Description Carlos Rafael Giani 2013-07-03 16:57:49 UTC
Created attachment 248333 [details] [review]
patch which adds the custom downstream sync event

Currently, rtpbin sends out RTP packets on a best-effort basis until it receives an RTCP SR packet. Once that happens, the bin is able to synchronize the packet timestamps. For downstream elements and applications, it is sometimes desirable to know when the SR packet was received (and therefore when rtpbin started to output with synchronization).

To accomplish this, this patch adds an option to rtpbin that enables a new custom in-band downstream event, called "GstRTCPSRReceived". This event is sent when the rtpbin receives an RTCP packet. (In-band, because out-of-band could result in the event arriving downstream before the synchronized buffers do.)

One example use case is when an application wishes to drop buffers until the rtpbin is synchronized. With this patch, the application can hook a probe to an RTP depayloader's src pad, and drop buffers until it sees the GstRTCPSRReceived event. Once this is done, the buffer switches from dropping to passing all buffers.

This is also useful to avoid synchronization problems with an audiosink's internal counters and timestamps.
Comment 1 Wim Taymans 2013-07-23 04:35:41 UTC
commit 95429f1d4ba2b2dd922d4edf606009960d34f722
Author: Carlos Rafael Giani <dv@pseudoterminal.org>
Date:   Wed Jul 3 18:41:42 2013 +0200

    rtpbin: added custom downstream sync event
    
    rtpbin can now send a custom in-band downstream event which informs
    downstream that the bin has received an RTCP SR packet. This is useful
    for applications which want to drop the initial unsynchronized received
    RTP packets.
    
    Fixes https://bugzilla.gnome.org/show_bug.cgi?id=703560
    
    Signed-off-by: Carlos Rafael Giani <dv@pseudoterminal.org>