Message-ID: <375D4B93.D24B7CA1@connect.ab.ca> Date: Tue, 08 Jun 1999 16:57:55 +0000 From: Tom Fjellstrom X-Mailer: Mozilla 4.6 [en] (Win95; I) X-Accept-Language: en MIME-Version: 1.0 Newsgroups: comp.os.msdos.djgpp Subject: Re: scare_mouse() alternatives? References: <8D53104ECD0CD211AF4000A0C9D60AE30140E96A AT probe-2 DOT acclaim-euro DOT net> <19990607123545 DOT A25332 AT tabor DOT ta DOT jcu DOT cz> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit NNTP-Posting-Host: pppa94.connect.ab.ca X-Trace: 8 Jun 1999 16:45:44 GMT, pppa94.connect.ab.ca Lines: 49 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com Hello, Allegro does let you show the cursor on a memory bitmap. Just use the show_mouse() function. (ie: BITMAP *buf=create_bitmap(SCREEN_W,SCREEN_H); clear(buf); show_mouse(buf); blit(buf,screen,0,0,0,0,buf->w,buf->h); :) At least this has always worked for me. Later. Tom Fjellstrom. Jan Hubicka wrote: > > On Mon, Jun 07, 1999 at 10:24:02AM +0100, Shawn Hargreaves wrote: > > Beholder1 writes: > > > I'm wondering, is there any way to write to the screen while having > > > a mouse present without having to call scare_mouse() every time? > > > > Not unless you are using a VBE/AF driver that supports hardware cursors. > > > > > When i scare the mouse, draw the screen, and then unscare the mouse, > > > I get an unattractive flicker. > > > > If you are doing a fully fledged screen animation, you need to make > > the mouse pointer be a part of that system. In other words don't use > > Allegro to draw the cursor at all, but just plot your own sprite > > using the same double buffering or page flipping system that you > > have in place for the rest of your graphics. > In XaoS I am just putting new bitmaps to the screen. In the rest > I would like to keep allegro's cursor just to make it working even > in cases XaoS is busy by calculating. > It can be nice, if allegro had some way to let me draw cursor to > bitmap (w/o removing original one on screen), putting bitmap with > the cursor to screen and then reventing back to normal mode draving > cursor on screen. This can avoid flickering in such bitmap blits. > I believe it is quite common situation, so maybe allegro can have > some support for this( or does it already have one?) > I've done this in the XaoS's direct-X driver and it seems to work nicely.. > > Honza > > > > > > Shawn Hargreaves.