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 680487 - avenc_wmav1: errors out with default bitrate - output buffer size is too small
avenc_wmav1: errors out with default bitrate - output buffer size is too small
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-libav
git master
Other Linux
: Normal normal
: 1.1.1
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2012-07-23 20:58 UTC by Jens Georg
Modified: 2012-12-05 18:41 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Jens Georg 2012-07-23 20:58:43 UTC
:00:02.951002477  5026      0x254c940 ERROR                  libav :0:: bitrate too low: got 0, need 24000 or higher
Comment 1 Tim-Philipp Müller 2012-07-23 21:55:39 UTC
$ gst-launch-1.0 audiotestsrc ! avenc_wmav1 ! fakesink -v
Setting pipeline to PAUSED ...
Pipeline is PREROLLING ...
/GstPipeline:pipeline0/GstAudioTestSrc:audiotestsrc0.GstPad:src: caps = audio/x-raw, format=(string)S16LE, layout=(string)interleaved, rate=(int)44100, channels=(int)1
0:00:02.265072799 24070       0xac1ca0 ERROR                  libav :0:: bitrate too low: got 0, need 24000 or higher
0:00:02.265920045 24070       0xac1ca0 ERROR                  libav :0:: bitrate too low: got 0, need 24000 or higher
0:00:02.292144673 24070       0xac1ca0 ERROR                  libav :0:: bitrate too low: got 0, need 24000 or higher
0:00:02.292843228 24070       0xac1ca0 ERROR                  libav :0:: bitrate too low: got 0, need 24000 or higher
0:00:02.293520411 24070       0xac1ca0 ERROR                  libav :0:: bitrate too low: got 0, need 24000 or higher
ERROR: from element /GstPipeline:pipeline0/GstAudioTestSrc:audiotestsrc0: Internal data flow error.
Additional debug info:
gstbasesrc.c(2742): gst_base_src_loop (): /GstPipeline:pipeline0/GstAudioTestSrc:audiotestsrc0:
streaming task paused, reason not-negotiated (-4)
ERROR: pipeline doesn't want to preroll.
Setting pipeline to NULL ...
Freeing pipeline ...
Comment 2 Tim-Philipp Müller 2012-10-29 00:19:33 UTC
Latest twist:

ERROR libav :0:: output buffer size is too small
ERROR libav gstavenc.c:386:gst_ffmpegaudenc_encode_audio:<avenc_wmav1-0> Failed to encode buffer: -22
Comment 3 Tim-Philipp Müller 2012-12-02 12:30:44 UTC
> ERROR libav gstavenc.c:386:gst_ffmpegaudenc_encode_audio:<avenc_wmav1-0> Failed
> to encode buffer: -22

This *appears* to be caused by:

    if (buf_size < 2 * MAX_CODED_SUPERFRAME_SIZE) {
        av_log(avctx, AV_LOG_ERROR, "output buffer size is too small\n");
        return AVERROR(EINVAL);
    }

in wmaenc.c, with 

 wma.h:#define MAX_CODED_SUPERFRAME_SIZE 16384

frame.

Since context->frame_size in set_format() is 2048, and we deliver that many samples, it looks like it might be a bug in liibav.

It works fine when forcing the input to channels=2, in which case context->frame_size is 8192 and it all works fine.
Comment 4 Sebastian Dröge (slomo) 2012-12-05 18:41:40 UTC
This is now fixed in latest GIT master.