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 763336 - mpegtsmux: subtitle stream is always selected for PCR
mpegtsmux: subtitle stream is always selected for PCR
Status: RESOLVED OBSOLETE
Product: GStreamer
Classification: Platform
Component: gst-plugins-bad
git master
Other Linux
: Normal normal
: git master
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2016-03-08 18:08 UTC by Vincent Génieux
Modified: 2018-11-03 13:47 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
avoid using a sparse stream in PCR selection (2.03 KB, patch)
2016-03-08 18:08 UTC, Vincent Génieux
reviewed Details | Review

Description Vincent Génieux 2016-03-08 18:08:29 UTC
Created attachment 323423 [details] [review]
avoid using a sparse stream in PCR selection

When using mpegtsmux, it appears that the subtitle pad is almost always chosen by the element as a PCR reference which is not really a good idea (audio or video stream would be a better idea to avoid latencies when muxing live streams).

This bug is reproducible with gst-launch-1.0 on git/master (+ patch from #759807) with a pipeline such as :

filesrc ! tsdemux name=d mpegtsmux name=m ! filesink d.video_0078 ! queue ! mpegvideoparse ! avdec_mpeg2video ! deinterlace ! videoscale ! video/x-raw,width=320,height=240 ! x264enc bitrate=1024 ! h264parse ! m. d.audio_0082 ! queue ! mpegaudioparse ! avdec_mp2float ! audioconvert ! voaacenc ! aacparse ! m. d.subpicture_008d ! queue ! subpicture/x-dvb ! m. d.subpicture_008e ! queue ! subpicture/x-dvb ! m

When using GST_DEBUG=mpegtsmux:5, we can see in the logs :
mpegtsmux.c:1188:mpegtsmux_collected_buffer:<m> Pads collected
mpegtsmux.c:598:mpegtsmux_create_stream:<m:sink_65> Creating stream with PID 0x0041 for caps video/x-h264, [...]
mpegtsmux.c:598:mpegtsmux_create_stream:<m:sink_66> Creating stream with PID 0x0042 for caps audio/mpeg, [...]
mpegtsmux.c:598:mpegtsmux_create_stream:<m:sink_67> Creating stream with PID 0x0043 for caps audio/mpeg, [...]
mpegtsmux.c:598:mpegtsmux_create_stream:<m:sink_68> Creating stream with PID 0x0044 for caps audio/mpeg, [...]
mpegtsmux.c:598:mpegtsmux_create_stream:<m:sink_69> Creating stream with PID 0x0045 for caps subpicture/x-dvb
mpegtsmux.c:598:mpegtsmux_create_stream:<m:sink_70> Creating stream with PID 0x0046 for caps subpicture/x-dvb
mpegtsmux.c:1271:mpegtsmux_collected_buffer:<m:sink_69> Use stream (pid=69) from pad as PCR for program (prog_id = 0)


-> see latest log line choosing sink_69 with caps subpicture/x-dvb

The proposed patch delay the PCR selection until the stream is not sparse.
Comment 1 Tim-Philipp Müller 2016-03-11 08:59:13 UTC
I think this makes sense, but what happens in case there's only a sparse stream?
Comment 2 Vincent Génieux 2016-03-11 10:20:22 UTC
Muxing only subtitles tracks works (it generates data that vlc can read without complain).

Note: gst-launch is displaying this errors twice :

(gst-launch-1.0:9489): GStreamer-CRITICAL **: gst_segment_to_running_time: assertion 'segment->format == format' failed

(it is also the case on the original master branch)
Comment 3 GStreamer system administrator 2018-11-03 13:47:36 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/358.