Re: [Vala] How to use Game loop style with Glib main loop(for events)?



Thank you. If I get you right, this will block events until I finish drawing, but that is the purpose.
And is it possible to do it multi-threaded? In a way that input thread is different than drawing thread?

Well, the glib mainloop always needs to be on the thread where glib is
initialized.
I don't see a reason why that can't be synchronized with a separate
rendering thread, but it seems likely that having to synchronize
threads for every loop iteration will be slower than just running both
loops on the main thread.



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]