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 637754 - multipartdemux: time stamp output buffer based on first input buffer not last
multipartdemux: time stamp output buffer based on first input buffer not last
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-good
git master
Other Linux
: Normal normal
: 1.1.4
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2010-12-21 15:40 UTC by American Dynamics
Modified: 2013-08-23 15:14 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description American Dynamics 2010-12-21 15:40:20 UTC
Hello,
We have developed an application in which we use the multipartdemux to assemble large video frames (which means many packets) “pushed” to this element via an http source.  And the current implementation of multipartdemux will use the reception time stamp of the most recent “packet” recvd as the timestamp when it finally pulls/sends assembled frames downstream.  On a congested network with retransmits, these packets-per-frame can be milliseconds apart.  For this reason we consider the time stamp of the first buffer in the frame more accurate than the timestamp of the last buffer in the frame.

Would it be possible for the multipartdemux element to be augmented to support the ability to use the reception time of the first packet when sending the assembled frame downstream instead of the timestamp of the most recently received packets’ timestamp?  And to create another property which would represent using the current implementation or using this new proposed implementation, defaulted to use the current implementation?  If this is deemed a good idea we can develop and submit a patch.

Thank you very much.
Comment 1 Tim-Philipp Müller 2013-08-22 08:06:30 UTC
If I understand you correctly, you are saying that in case multipartdemux assembles an output buffer from multiple input buffers, and the input buffers carry timestamps, then it will timestamp the output buffer based on the timestamp of the last input buffer rather than the first one?

If that is indeed the case (to be confirmed), I would agree with you that it should be timestamped based on the timestamp of the first contributing input buffer.
Comment 2 Tim-Philipp Müller 2013-08-22 14:25:38 UTC
Still an issue it seems:
$ gst-launch-1.0 filesrc location=/home/tpm/samples/misc/635734-some-frames-have-no-eoi-marker-mjpeg.multipart ! queue ! identity datarate=100000 ! identity silent=false ! multipartdemux ! fakesink silent=false -v 2>/dev/null | grep pts | more

IN  pts 0:00:00.000000000
IN  pts 0:00:00.040960000
IN  pts 0:00:00.081920000
IN  pts 0:00:00.122880000
IN  pts 0:00:00.163840000
IN  pts 0:00:00.204800000
OUT pts 0:00:00.000000000

IN  pts 0:00:00.245760000
IN  pts 0:00:00.286720000
IN  pts 0:00:00.327680000
IN  pts 0:00:00.368640000
IN  pts 0:00:00.409600000
OUT pts 0:00:00.409600000

IN  pts 0:00:00.450560000
IN  pts 0:00:00.491520000
OUT pts 0:00:00.491520000

IN  pts 0:00:00.532480000
IN  pts 0:00:00.573440000
IN  pts 0:00:00.614400000
IN  pts 0:00:00.655360000
IN  pts 0:00:00.696320000
OUT pts 0:00:00.696320000
Comment 3 Tim-Philipp Müller 2013-08-23 15:14:07 UTC
commit 7d78a68c8de0c866b7e196b8f22cc5f3cc14a3a3
Author: Tim-Philipp Müller <tim@centricular.net>
Date:   Fri Aug 23 15:29:28 2013 +0100

    multipartdemux: timestamp output buffers based on first input buffer that provided bytes not last
    
    https://bugzilla.gnome.org/show_bug.cgi?id=637754