questions abount shmsrc and adder,how to avoid the critical message?

Tim-Philipp Müller t.i.m at zen.co.uk
Sat Jun 29 06:37:00 PDT 2013


On Sat, 2013-06-29 at 01:26 -0700, Jerry wrote:

Hi,

> I am using shmsrc to get the audio stream and using adder to mixer the
> sound, and the follow is my pipeline:
> shmsrc-->caps-->alawdec-->queue-->|
>                                                       |-->adder-->alsasink
> shmsrc-->caps-->alawdec-->queue-->|
> The pipeline works,but appears this message:
> ** (kd-svc-helper:1724): CRITICAL **: gst_audio_buffer_clip: assertion
> `segment->format == GST_FORMAT_TIME || segment->format ==
> GST_FORMAT_DEFAULT' failed
> I want to avoid this message, anyone help?

You could try:

 gst_base_src_set_format (GST_BASE_SRC (shmsrc), GST_FORMAT_TIME);

before you start the pipeline. But even then you're probably (not really
sure) missing timestamps on the buffers. Though with alaw at least you
have a constant bitrate, so you could use identity datarate=N where N is
sample_rate * channels or so (IIRC).

http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer-libs/html/GstBaseSrc.html#gst-base-src-set-format

Cheers
 -Tim



More information about the gstreamer-devel mailing list