[gstreamer-bugs] [Bug 591934] timestamp drift in audioresample

GStreamer (bugzilla.gnome.org) bugzilla at gnome.org
Tue Aug 18 23:06:50 PDT 2009


http://bugzilla.gnome.org/show_bug.cgi?id=591934



--- Comment #15 from Sebastian Dröge <slomo at circular-chaos.org> 2009-08-19 06:06:47 UTC ---
(In reply to comment #13)
> Created an attachment (id=141129) [details]
> fix buffer overflow in push_drain()
> 
> the original patch introduced a buffer overflow into the push_drain() method. 
> this patch fixes it.  Needs to be applied on top of patch 140863 [details].

Oh right, thanks. That's of course the right thing to do :) You don't need to
include gstutils.h though, that's already included as part of gst.h. I'll
remove that when committing it.

(In reply to comment #14)
> I'm not sure if this is an appropriate unit test, but the following pipeline
> can be used to detect the timestamp drift from the command line:
> 
> gst-launch \
>         audiotestsrc wave=0 freq=1024 samplesperbuffer=10 num-buffers=1000000 \
>         ! audio/x-raw-float, channels=1, width=64, rate=16384 \
>         ! audioresample \
>         ! audio/x-raw-float, rate=4096 \
>         ! testsink sync=false allowed-timestamp-deviation=0
> 
> With the original resampler, this pipeline terminates with the message
> 
> ERROR: from element /GstPipeline:pipeline0/GstTest:test0: The stream is in the
> wrong format.
> Additional debug info:
> testplugin.c(223): gst_test_sink_event ():
> /GstPipeline:pipeline0/GstTest:test0:
> test timestamp-deviation returned value "8" and not expected value "0"
> 
> with the patched version, the pipeline runs to completion without an error
> message.
> 
> Unfortunately gst-launch doesn't exit with a non-zero exit code when the
> pipeline emits an error, so it's not easy to test for the failure from a shell
> script.  One could grep for "timestamp-deviation" in the output to stderr:

That's not exactly what we need, also testsink is not part of any gstreamer
modules yet (would be nice to have patches to get testsink and nxydump into
gst-plugins-bad btw).

What we need is some code to do essentially what your gst-launch line does.
Take a look at the existing code in tests/check/elements/audioresample.c for
example. Whatever, I'll write a testcase for that later and attach it here too
;)

-- 
Configure bugmail: http://bugzilla.gnome.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.



More information about the Gstreamer-bugs mailing list