GNOME Bugzilla – Bug 791348
interaudio: Drain samples before setting new caps
Last modified: 2018-11-03 14:16:08 UTC
Currently, when caps change, any samples remaining inside the channel are thrown away, causing data loss. Fix this by draining them before the caps are changed in gst_inter_audio_sink_set_caps().
Created attachment 365200 [details] [review] interaudiosrc caps change sample drain patch
Created attachment 365205 [details] [review] interaudiosrc caps change sample drain patch v2 Previous version incorrectly removed a g_mutex_unlock call.
Makes sense. Any chance to get a unit test as well? Shouldn't be very complicated - push caps1, buffer1, caps2, buffer2 and check output?
Right, makes sense. It is odd though that the inter plugin seems to come with its own integrated test code (gstintertest.c). Isn't this duplicating test framework functionality?
Comment on attachment 365205 [details] [review] interaudiosrc caps change sample drain patch v2 Doesn't compile when applied to master.
-- 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/637.