From: "Michael Stewart" Newsgroups: comp.os.msdos.djgpp Subject: Re: Fades Date: Thu, 18 Mar 1999 19:31:29 -0000 Organization: Customer of Planet Online Lines: 75 Message-ID: <7crlco$rg5$1@news5.svr.pol.co.uk> References: <36ED4D0B DOT 78A2B9ED AT geocities DOT com> NNTP-Posting-Host: modem-75.sulfur.dialup.pol.co.uk X-Trace: news5.svr.pol.co.uk 921786584 28165 62.136.7.203 (18 Mar 1999 19:49:44 GMT) NNTP-Posting-Date: 18 Mar 1999 19:49:44 GMT X-Complaints-To: abuse AT theplanet DOT net X-Newsreader: Microsoft Outlook Express 4.72.3110.5 X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3110.3 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com The Beyonder wrote in message <36ED4D0B DOT 78A2B9ED AT geocities DOT com>... >IIRC That's sorta harder because each individual pixel on the screen has >to be changed to the next colour... but all you really have to do is go >through the SVGA virtual frame buffer and start changing the pixels FI: > > >RGB pixValue; > >while (!allFade) { > for (int i=0;i pixValue = getPixel24( x,y ); > FadeStep ( &pixValue ); > putPixel24( x,y, pixValue ); > } >} > > >or some such. But I believe that there has to be a better method >availabe... > >John Carbrey wrote: >> >> All the fade functions that I have seen so far only allow for 256 colors. Is >> there a way I can fade in 16,24,or 32 bit color? >> >> Yt, >> >> John Carbrey > >-- >********************************************************************** >* Sahab Yazdani * OpenDOS - Why go through windows when * >* Thornhill Secondary School * you could have a !&$^&* DOOR? * >********************************************************************** >* http://www.geocities.com/TimesSquare/Bunker/8994/index.html * >:-P * >* Click the link to visit my portion of The Neverhood * <:-D * >********************************************************************** I asked Shawn Hargreaves a similar question, this is a copy of the message: > > >I'm of two minds as to include colour fading in my routines. > >Now, palette fading is easy and relatively efficient to do in indexed > colour > >modes. But is there a efficient way (without hardware support) to perform > >the same effect in 15/16/24/32 bit direct colour modes ? > > Not that I have ever come across. > > >I cannot think of any methods of performing it well. The only way of > doing > >it, that I can think of, is to perform a colour fade on a per pixel > level. > > Yeah, it is a pain in the arse but I think that is what you have to do. > One easy way to implement this is just to repeatedly draw a black > translucent rectangle covering the entire screen, which will gradually > darken it down. But this is painfully slow: I think that is one of the > biggest disadvantages of switching from a 256 color to truecolor mode. > > -- > Shawn Hargreaves - shawn AT talula DOT demon DOT co DOT uk - > http://www.talula.demon.co.uk/ > "Without music to decorate it, time is just a bunch of boring production > deadlines or dates by which bills must be paid." - Frank Zappa > -- Michael Stewart mike AT reggin DOT freeserve DOT co DOT uk "Just because you're paraniod doesn't mean they aren't after you..."