Re: frozen GUI!!! urgent help required!



On Tue, 12 Mar 2002 RevX gmx at wrote:

> Hello all,
>
> I've the following situation in/with my GUI (actually
> I'm using Gtk--, but that shouldn't matter because
> Gtk-- is only a wrapper for Gtk+):
> A checkbutton gets pressed and calculations
> begin (involving retrieving of images from a
> video camera and processing them). And
> at this moment the GUI is frozen, no buttons
> are clickable anymore and the window isn't
> redrawn when temporary overlapped by other
> windows. It looks like as if everything is frozen.
>
> So, what is going wrong??? Does the GUI of
> Gtk+ not run parallel to the calculations to fetch
> X events or is it a fault I just don't see?!
> I hope someone can help me (soon).
> Thanks for helping in advance.
>

this is because when you start doing the heavy computations your program
won't be able to catch gui events ... it will be able to catch them again
when the computations complete and the sequential flow of your program
enters a gtk_main again.
if you want to compute and process events in a parallel/concurrent fashion
you will have to use threads/processes.
M.

 ____                 _____
|  _ \  ___ ___  _ __| ____|
| | | |/ __/ _ \| '__|  _|
| |_| | (_| (_) | |  | |___
|____/ \___\___/|_|  |_____|





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