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 765796 - rtp depayloaders output bad segment events when input stream is a non time segment
rtp depayloaders output bad segment events when input stream is a non time se...
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-base
git master
Other Mac OS
: Normal normal
: 1.11.1
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2016-04-29 08:06 UTC by Zaheer Abbas Merali
Modified: 2016-11-01 19:09 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch to fix and test to validate (2.78 KB, application/mbox)
2016-04-29 08:06 UTC, Zaheer Abbas Merali
  Details
Patch to fix and test to validate (2.78 KB, patch)
2016-04-29 08:07 UTC, Zaheer Abbas Merali
needs-work Details | Review
rtpbasedepayload: Reject non-TIME segments (1.20 KB, patch)
2016-05-02 06:48 UTC, Sebastian Dröge (slomo)
committed Details | Review
basertpdepayload: create valid segment when given non-time segment (1.60 KB, patch)
2016-05-02 06:51 UTC, Sebastian Dröge (slomo)
committed Details | Review

Description Zaheer Abbas Merali 2016-04-29 08:06:52 UTC
Created attachment 326991 [details]
Patch to fix and test to validate

This happens when doing appsrc ! <depayloader> ! ...

depayloaders then generate a new segment event with base=-1 which makes buffers it outputs afterwards not be valid for the segment.
Comment 1 Zaheer Abbas Merali 2016-04-29 08:07:36 UTC
Created attachment 326992 [details] [review]
Patch to fix and test to validate
Comment 2 Zaheer Abbas Merali 2016-04-29 08:08:45 UTC
It would be great to have this patch applied to 1.6 as well as current also.
Comment 3 Sebastian Dröge (slomo) 2016-04-29 08:18:04 UTC
A non-TIME segment for RTP data is not really valid, I expect you'll run into more problems with that :)
Comment 4 Sebastian Dröge (slomo) 2016-04-29 08:19:16 UTC
Meaning, the depayloader should probably completely reject the segment.


(There will also be no further 1.6 release, but backporting a fix to the 1.6 branch should be possible, depending on the fix)
Comment 5 Tim-Philipp Müller 2016-04-29 08:25:15 UTC
I don't think it's a good idea to make rtp depayloaders accept non-TIME segments, you configure appsrc to create a TIME segment IMHO.
Comment 6 Zaheer Abbas Merali 2016-04-29 08:28:29 UTC
currently the depayloaders do accept non-TIME segments. Just they output a bad new segment event. I'd be fine if we patched the basedepayloader to completely reject non-TIME segments too but the current status-quo made it take quite a while to debug some other weirdness further down the pipeline from the depayloader.
Comment 7 Sebastian Dröge (slomo) 2016-04-29 08:37:34 UTC
Yes it should just reject the segment, see comment 4. It doesn't make sense to work with RTP on a non-TIME segment.
Comment 8 Tim-Philipp Müller 2016-04-30 14:23:52 UTC
Having said that, we should probably apply the patch to 1.8/1.6 and log a GST_ERROR() if it's a non-TIME segment; in master we can then take more drastic measures to reject it if we want (whatever those might be).
Comment 9 Sebastian Dröge (slomo) 2016-05-02 06:48:29 UTC
Created attachment 327130 [details] [review]
rtpbasedepayload: Reject non-TIME segments
Comment 10 Sebastian Dröge (slomo) 2016-05-02 06:51:57 UTC
Created attachment 327131 [details] [review]
basertpdepayload: create valid segment when given non-time segment

This will become an error in 1.10.
Comment 11 Sebastian Dröge (slomo) 2016-05-02 06:52:32 UTC
Something like this? I removed the unit test as it will just fail in git master and it's unsupported behaviour
Comment 12 Olivier Crête 2016-05-18 19:01:41 UTC
See #766438 for a patch that makes this work through the JB, so you can do something like appsrc ! rtpjitterbuffer ! rtp*depay ..
Comment 13 Sebastian Dröge (slomo) 2016-07-01 12:17:04 UTC
Comment on attachment 327131 [details] [review]
basertpdepayload: create valid segment when given non-time segment

Attachment 327131 [details] pushed as 0f609bc - basertpdepayload: create valid segment when given non-time segment
Comment 14 Sebastian Dröge (slomo) 2016-07-01 12:19:02 UTC
For 1.12 we can merge the other patch then, or not.
Comment 15 Sebastian Dröge (slomo) 2016-11-01 18:45:18 UTC
Olivier, what should we do here?
Comment 16 Olivier Crête 2016-11-01 19:05:17 UTC
I'd say let's push the patch, the jitterbuffer now has code to generate a TIME segment so you can do "multifilesrc ! rtpjitterbuffer ! depay ! ..." and that should work.
Comment 17 Sebastian Dröge (slomo) 2016-11-01 19:09:32 UTC
Attachment 327130 [details] pushed as d84879d - rtpbasedepayload: Reject non-TIME segments