Jump to content

  • Log In with Google      Sign In   
  • Create Account


Best way to draw a 16 bit dib


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
1 reply to this topic

#1 Lerc   Members   -  Reputation: 122

Like
Likes
Like

Posted 10 September 1999 - 04:54 AM

What is the fastest way to reliably place a dib onto the screen?

Windows has a whole heap of ways to achieve this.

BitBlt works, and works well on some systems. but appallingly on other systems. On a system with an i740 it took 1.5Million clocks to put the 640x480 dib onscreen. On my system (also an i740) it takes 3.5M clocks.
On one system however it takes 37M clocks to do the blit.

All blits are going onto 16 bit displays. I can only assume that diffent drivers and different bit orderings affect the speed greatly.

is SetDIBitsToDevice any better or more consistant. How about DirectDraw functions.

I'm pretty much only going to be rendering into 565 RGB color. I'm prepared to render directly into a directdraw surface only if I can be guaranteed a 565 Surface.

If I cant't be guaranteed a 565 Surface then I'll render into system memory. Does DirectDraw provide any blit functions to to the bit remap faster than BitBlt.

Any help/comments would be appreciated.


Sponsor:

#2 Anonymous Poster_Anonymous Poster_*   Guests   -  Reputation:

Likes

Posted 10 September 1999 - 04:54 AM

You can't rely on 565 - the HW sets this, and most gfx boards support either 555 or 565, but not both.

Bitblt sucks big time, DX is generally faster and lets you decide for yourself if you wish to use HW blits in video mem, or SW in system mem.. DX essentially gives you a pointer to a chunk of memory, and the rest is up to you.

The penalty for the fast display access is the need to deal with pixel formats etc., but it IS well worth it...

/NJ





Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS