From: Stephan B. <sb...@op...> - 2003-09-29 09:00:31
|
Hello! I have a problem with the X11 driver of Allegro. If I do the following, the mouse pointer is not updated (removed) correctly: for(;;) { acquire_screen(); show_mouse(NULL); draw something on the screen show_mouse(screen); release_screen(); wait for some time } I tested on two different linux machine with two different X11 servers/set of libraries. It does not fail under Windows and Linux/vgalib. To be (more or less) sure that the problem is caused by Allegro, I extended example program exmouse.c in the Allegro source tree as follows: diff exmouse.c.orig exmouse.c 126a127,152 > #if 1 > { > int i,j; > > i=0; > for(;;) > { > acquire_screen(); > show_mouse(NULL); > rectfill(screen,10,10,150,50,i); > show_mouse(screen); > release_screen(); > i++; > if(i==256) > i=0; > for(j=0;j<10;j++) > { > /*#define AVOID_PROBLEM*/ > #ifdef AVOID_PROBLEM > show_mouse(screen); > #endif > yield_timeslice(); > } > } > } > #else 127a154 > #endif Increasing the number of times "yield_timeslice()" is called increases the problem/let's the problem show up, enabling "show_mouse(screen)" by setting "AVOID_PROBLEM" solves it. Is this a already known issue? Stephan |