<html dir="ltr"><head></head><body style="text-align:left; direction:ltr;"><div>Hello,</div><div><br></div><div>On Fri, 2018-08-24 at 19:37 +0200, Hadrien Titeux wrote:</div><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><div>So, here are what I'd like to know:</div><div>- Is it possible to play a .wav file without saving it to disk first? Like, directly from the byte file stored in the python memory (as portaudio can do it)</div></blockquote><div><br></div><div>Totally possible, you can use "appsrc" instead of a filesrc and then just give it buffers.</div><div><br></div><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><div>- The websocket receives sounds asynchronously with the asyncio module. I've seen that Gbulb permits the use of the Gtk event loop with asyncio. I'll be thus receiving sound bites that i'll have to play right at the moment I receive them through my websocket client, sometimes overlapping each other when they're being played. This requires asynchronously mixing several audio files. Do you think this is feasible with the gst bindings? </div></blockquote><div><br></div><div>Yes, you would do that with multiple appsrcs, you want to make it a livesrc and set "do-timestamp" to true on them. Then mix them with the new "audiomixer", but make sure there is a "live" source connected when it starts. You should probably set all of your appsrc instances to be live.</div><div><br></div><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><div><br></div><div>To give you an idea of what i'd expect, here's the portaudio implementation of what I need: <a href="https://github.com/loult-elte-fwere/termiloult/blob/master/tools/audiosink.py">https://github.com/loult-elte-fwere/termiloult/blob/master/tools/audiosink.py</a> </div><div><br></div><div>I can't find any documentation on this kind of usage of gstreamer, apart from the cold PyGObject API reference.</div></blockquote><div><br></div><div>Your usecase is indeed a bit special, so I don't think you'll find any written documentation.</div><div><br></div><div>Olivier</div><div><span style="position: absolute; opacity: 0;"><a href="https://twitter.com/Bodegacats_/status/1034042708074135553">https://twitter.com/Bodegacats_/status/1034042708074135553</a></span><span style="position: absolute; opacity: 0;"><br></span><span style="position: absolute; opacity: 0;"><br></span></div><div><br></div><blockquote type="cite" style="margin:0 0 0 .8ex; border-left:2px #729fcf solid;padding-left:1ex"><div><br></div><div>Thanks in advance for your help,</div><div>Hadrien</div><pre>_______________________________________________</pre><pre>gstreamer-devel mailing list</pre><pre><a href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a></pre><pre><a href="https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel">https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a></pre><pre><br></pre></blockquote><div><span><pre><pre>-- <br></pre>Olivier CrĂȘte
olivier.crete@collabora.com
</pre></span></div></body></html>