Re: Sweeping out old events




Daniel Skarda <0rfelyus@atrey.karlin.mff.cuni.cz> writes:

> Hello,
> 
>   I have following problem: in my program there is an OpenGL widget. According
> to the mouse movement I rotate whole scene. Unfortunately mouse events
> ("motion_notify_event") come in at higher rate than OpenGL can redraw scene. So
> my question is: how can I erase too old events or how to detect that this event
> can be ignored (since there is new mouse position somewhere in the queue).

For mouse events, the best way to do this is by use 
GTK_POINTER_MOTION_HINT_MASK. See the Scribble section of the
tutorial for more information.

Regards,
                                        Owen



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