<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <p>You could try adding a queue to each of your branches, since the
      lamemp3enc might have a very small buffer, (or playbin), you will
      need to have a small amount so it can play and record at the same
      time.  By default gstreamer will try to synchronize all sinks such
      that they "play" the same sample at the same time.</p>
    <p>So you could try something like this (bolded the added queues for
      clarity):</p>
    <pre wrap="">$ gst-launch-1.0 souphttpsrc location=<livestream url> ! decodebin !
audioconvert ! tee name=t <b>! queue</b> ! playsink t. <b>! queue</b> ! lamemp3enc ! id3v2mux ! filesink
location=test.mp3</pre>
    Hope that helps!<br>
    <br>
    <br>
    <div class="moz-cite-prefix">On 9/26/2018 8:15 AM, ben_whiteus
      wrote:<br>
    </div>
    <blockquote type="cite"
      cite="mid:1537974945170-0.post@n4.nabble.com">
      <pre wrap="">I was able to play and record Internet stream using gstreamer when I was
using Ubuntu 16.04. However, after upgrading to 18.04, I can no longer do
that. The command I used and the corresponding error message are as follows:

$ gst-launch-1.0 souphttpsrc location=<livestream url> ! decodebin !
audioconvert ! tee name=t ! playsink t. ! lamemp3enc ! id3v2mux ! filesink
location=test.mp3
Setting pipeline to PAUSED ...
Pipeline is PREROLLING ...
Got context from element 'souphttpsrc0': gst.soup.session=context,
session=(SoupSession)NULL, force=(boolean)false;
Redistribute latency...
Redistribute latency...
^Chandling interrupt.
Interrupt: Stopping pipeline ...
ERROR: pipeline doesn't want to preroll.
Setting pipeline to NULL ...
Freeing pipeline ...

I did try playing alone: 

$ gst-launch-1.0 souphttpsrc location=<livestream url> ! decodebin !
audioconvert !  playsink
Setting pipeline to PAUSED ...
Pipeline is PREROLLING ...
Got context from element 'souphttpsrc0': gst.soup.session=context,
session=(SoupSession)NULL, force=(boolean)false;
Redistribute latency...
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstPulseSinkClock
^Chandling interrupt.
Interrupt: Stopping pipeline ...
Execution ended after 0:00:17.987984164
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...

and recording alone: 

$ gst-launch-1.0 souphttpsrc location=<livestream url> ! decodebin !
audioconvert ! lamemp3enc ! id3v2mux ! filesink location=test.mp3
Pipeline is PREROLLING ...
Got context from element 'souphttpsrc0': gst.soup.session=context,
session=(SoupSession)NULL, force=(boolean)false;
Redistribute latency...
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
^Chandling interrupt.
Interrupt: Stopping pipeline ...
Execution ended after 0:00:16.354333158
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...

and both works fine.

Any idea how I can resolve the issue? 

Thanks



--
Sent from: <a class="moz-txt-link-freetext" href="http://gstreamer-devel.966125.n4.nabble.com/">http://gstreamer-devel.966125.n4.nabble.com/</a>
_______________________________________________
gstreamer-devel mailing list
<a class="moz-txt-link-abbreviated" href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a>
<a class="moz-txt-link-freetext" href="https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel">https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a>


</pre>
    </blockquote>
    <br>
  </body>
</html>