[Bug 732908] New: audioresample skips samples unless input buffers have correct size

GStreamer (bugzilla.gnome.org) bugzilla at gnome.org
Tue Jul 8 09:57:17 PDT 2014


https://bugzilla.gnome.org/show_bug.cgi?id=732908
  GStreamer | gst-plugins-base | unspecified

           Summary: audioresample skips samples unless input buffers have
                    correct size
    Classification: Platform
           Product: GStreamer
           Version: unspecified
        OS/Version: Linux
            Status: UNCONFIRMED
          Severity: major
          Priority: Normal
         Component: gst-plugins-base
        AssignedTo: gstreamer-bugs at lists.freedesktop.org
        ReportedBy: kcannon at cita.utoronto.ca
         QAContact: gstreamer-bugs at lists.freedesktop.org
     GNOME version: ---


Created an attachment (id=280172)
 View: https://bugzilla.gnome.org/attachment.cgi?id=280172
 Review: https://bugzilla.gnome.org/review?bug=732908&attachment=280172

fix dropping of input samples when downsampling

when the resampler is fed buffers with an unlucky number of samples in them, it
drops samples from the input stream causing a phase (= timestamp) drift in its
output.  I think this might be the cause of a number of userspace audio
problems I have experienced involving stuttering.  this is actually a very
serious bug for the work we're doing so I have taken the liberty of putting the
severity at major.

the bug is easily seen with the following

$ gst-launch-1.0 \
    audiotestsrc freq=16 wave=sine samplesperbuffer=170 num-buffers=24 \
    ! audio/x-raw, format=F64LE, channels=1, rate=4096 \
    ! tee name=input \
    ! audioresample quality=1 \
    ! audio/x-raw, rate=64 \
    ! tsvenc ! filesink location="dump.out" sync=false async=false \
    input. ! tsvenc ! filesink location="dump.in" sync=false async=false \

to run that you will need to apply the tsvenc patch to the debugutilsbad plugin
to get the time series dumps in ascii, otherwise you can do whatever you want
to look at the streams.

a patch is attached that fixes it, and I have also attached plots of the output
of the pipeline above before and after applying the patch.

-- 
Configure bugmail: https://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