OpenSLESSrc negotiation issues

Sérgio Agostinho sergio.r.agostinho at gmail.com
Wed Jan 28 02:48:05 PST 2015


Over the past day I had some issues with openslessrc, that I think it might
be useful to share. I have a pipeline with a multiple bins. For the current
example, only the following two are important

audio_src_bin = openslessrc ! audio/x-raw, rate=16000, format=S16LE,
channels=1 ! tee
audio_tcp_sink_bin = queue ! audioconvert ! audioresample ! audio/x-raw,
channels=1, rate=16000, format=S16LE ! tcpserversink

which connect to each other like this
audio_src_bin ! audio_tcp_sink_bin

When I initially create the elements, add them to the bins and link them
together (elements and bins), I was getting no negotiation error. However
when I set audio_src_bin to PLAYING, it refused and gave me the infamous
"reason not-negotiated (-4)". After increasing the debug log verbose for
openslessrc I managed to get the following message

01-28 11:04:23.564  10725-11004/esa.mobipv E/GStreamer+default﹕
> 0:00:08.014928851 0x7ccf6a60 audio-info.c:267:gst_audio_info_from_caps no
> layout given
> 01-28 11:04:23.564  10725-11004/esa.mobipv W/GStreamer+basesrc﹕
> 0:00:08.015023642 0x7ccf6a60
> gstbasesrc.c:2933:gst_base_src_loop:<audio_src> error: Internal data flow
> error.
> 01-28 11:04:23.564  10725-11004/esa.mobipv W/GStreamer+basesrc﹕
> 0:00:08.015080778 0x7ccf6a60
> gstbasesrc.c:2933:gst_base_src_loop:<audio_src> error: streaming task
> paused, reason not-negotiated (-4)


To fix this I had to manually specifiy
audio_src_bin = openslessrc ! audio/x-raw, rate=16000, format=S16LE,
channels=1, *layout=interleaved* ! tee

What I found strange is that if I didn't specify the layout, I could not
even make a bin like this work.
openslessrc ! fakesink

Nothing should have negotiation issues with fakesink. The element supports
all capabilities. Also it would be beneficial to have the layout appear in
the elements capabilities, when using gst-inspect. At least it would
provide a hint. Currently it only gives this

Pad Templates:
>   SRC template: 'src'
>     Availability: Always
>     Capabilities:
>       audio/x-raw
>                  format: S16LE
>                    rate: 16000
>                channels: 1


Cheers,
Sérgio
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20150128/c2bce10b/attachment.html>


More information about the gstreamer-devel mailing list