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 797016 - Appsink: does not respect allocation query being serialized
Appsink: does not respect allocation query being serialized
Status: RESOLVED OBSOLETE
Product: GStreamer
Classification: Platform
Component: gst-plugins-base
git master
Other All
: Normal normal
: git master
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2018-08-23 08:33 UTC by Dimitrios Katsaros
Modified: 2018-11-03 12:09 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Demo of how allocation query handing is not being respected (2.38 KB, text/x-csrc)
2018-08-23 08:33 UTC, Dimitrios Katsaros
  Details
Patch to make allocation query be serialized (1.05 KB, patch)
2018-08-23 08:35 UTC, Dimitrios Katsaros
none Details | Review
Made the appsink queries respect all serialized queries (2.85 KB, patch)
2018-08-23 08:53 UTC, Dimitrios Katsaros
none Details | Review
Updated demo on how allocation query handling is not being respected (2.36 KB, text/x-csrc)
2018-08-24 08:49 UTC, Dimitrios Katsaros
  Details
Test updated to check for drain for any serialized query (3.32 KB, patch)
2018-08-27 09:24 UTC, Dimitrios Katsaros
none Details | Review

Description Dimitrios Katsaros 2018-08-23 08:33:46 UTC
Created attachment 373433 [details]
Demo of how allocation query handing is not being respected

The allocation query is serialized, which means that it should respect the flow of data and follow after all buffers that have come before it. However, appsink does not respect this. I have added a demo showing how this behavior breaks v4l2src functionality. I have also added a simple patch for fixing the issue, by calling the same code that GST_QUERY_DRAIN runs.
Comment 1 Dimitrios Katsaros 2018-08-23 08:35:12 UTC
Created attachment 373434 [details] [review]
Patch to make allocation query be serialized
Comment 2 Dimitrios Katsaros 2018-08-23 08:53:06 UTC
Created attachment 373439 [details] [review]
Made the appsink queries respect all serialized queries
Comment 3 Dimitrios Katsaros 2018-08-24 08:49:23 UTC
Created attachment 373452 [details]
Updated demo on how allocation query handling is not being respected
Comment 4 Julien Isorce 2018-08-25 06:23:55 UTC
So now all serialized queries do a drain ? In any case can you make your demo a test that fails without the patch and succeeds with the patch. See existing tests https://cgit.freedesktop.org/gstreamer/gst-plugins-base/tree/tests/check/elements/appsink.c .
Thx!
Comment 5 Nicolas Dufresne (ndufresne) 2018-08-25 13:52:51 UTC
I think it makes sense, unlike events, we can't just put them in the queue. I'm pretty sure queue element do the same. Now, from there, we should start thinking of a mechanism to handle these query, because it makes me realize that using a pad probe (like i did in kmscube) would mean handling the query before the queue and the same issues would happen.
Comment 6 Dimitrios Katsaros 2018-08-27 09:24:41 UTC
Created attachment 373460 [details] [review]
Test updated to check for drain for any serialized query
Comment 7 GStreamer system administrator 2018-11-03 12:09:32 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-base/issues/478.