New, also help on dealing with multiple audio streams using gstreamer-rs

Sebastian Dröge sebastian at centricular.com
Thu Dec 17 14:03:11 UTC 2020


On Thu, 2020-12-17 at 13:49 +0000, Michael Johnson wrote:
> All those warnings are related to not handling the None type, I
> didn't think that would have any bearing. 

You were ignoring Results. set_property(), emit(), etc return Results.

> Wait. You're not supposed to use emit? Then why does it exist? Surely
> you emit a signal to then be caught by the connect.
> 
> What is the alternative to using emit then, and why does the
> alternative still relate to connect? 

One side is connecting to a signal, the other side is emitting signals.
For normal signals, the emitter is the object itself. In this case
playbin.

For action signals (get-audio-tags on playbin for example), you would
emit the signal instead of playbin. Action signals "abuse" the signal
machinery for having something like "dynamic function calls".

> By the logic of setting the value of 2 every them then current audio
> should go -1,-1,2 not -1,-1,-1. It yields 2 on exit. Which was my
> point

You print the current value before you set it to the new one. So in the
end it is 2, but you don't print it anymore.

-- 
Sebastian Dröge, Centricular Ltd · https://www.centricular.com

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/gstreamer-devel/attachments/20201217/9a3f4a68/attachment.htm>


More information about the gstreamer-devel mailing list