-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Why does mainloop quit, when core_event::done is fired? #10
Comments
Hi, thanks for the kind words! The default overload for bind issues a core update, which in turn calls quit. You can prevent this by passing I have to admit I'm not sure what my reasoning behind this design decision was, I'll quickly glance over it again and maybe change the default behavior. |
Alright, caught up to speed again - The This is why it currently quits the main-loop after processing all nodes within the callback - the goal was to make it as convenient to use as possible, which includes not having to wait explicitly wait for the bound object to be available.
I could look into providing an approach which stays more faithful to the default pipewire behavior, where a callback would get fired once the object was bound successfully² - in case that's something you'd want?
|
Ok, i guess i understand your ideas. However, i believe that the implemented behavior is a little inconsistent: To come back to your suggestion: Thanks already! |
Yes - This is what happens when you use the default bind overload. As mentioned previously, you can either pass
I'm not sure how the current behavior impacts this, in the examples a simple while loop is used to run the main-loop as long as required, you could simply set the loop condition to false and then quit the main-loop explicitly. Integrating the pipewire mainloop into an arbitrary other main-loop is quite difficult, as mentioned previously, pipewire does not offer a non blocking run.
Agreed! I'll start work on this when I find the time to do so ^^ |
Hi there and thanks for this nice pipewire wrapper.
I have a question:
consider this code snippet:
This will run and quit as soon as all nodes are printed. Why is this happening? Actually, it should continue and print all nodes that are subsequently added.
Thanks in advance!
The text was updated successfully, but these errors were encountered: