[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
Refreshing windows as often as possible, but not too often
- From: Ben Laurie <ben algroup co uk>
- To: GNOME Apps <gtk-app-devel-list redhat com>
- Subject: Refreshing windows as often as possible, but not too often
- Date: Sat, 09 Oct 1999 23:08:57 +0100
This is probably a really stupid question, but here goes...
For various reasons, which I'll go into if anyone cares, I'm writing a
Brooktree video capture prog for GTK. This works fine, but ... I have a
really irritating problem. Using a technique copied from, err, somewhere
(gnoghurt?), the way I do it is to make a pixmap the background of a
window, copy the current frame to the pixmap, and clear the window, with
gdk_window_clear(). I do this from an idle function, using
gtk_idle_add(). The snag is that it _really_ interferes with user
interaction. The mouse is like treacle, it takes ages to shut down,
window focus doesn't work, and so on.
Using nice(5) or so reduces the problem, but it comes back after a
while. Inserting a 1/10 second nap into each iteration helps, too. But
that's crap. So how do I do it _right_??
Code available if anyone wants it (just proof-of-principle at the mo. Or
disproof would be more accurate :-).
Cheers,
Ben.
--
http://www.apache-ssl.org/ben.html
"My grandfather once told me that there are two kinds of people: those
who work and those who take the credit. He told me to try to be in the
first group; there was less competition there."
- Indira Gandhi
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]