Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.


Understanding DirectDraw ...

This topic is 6129 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi... I''m currently learning DirectDraw, but there''s a point I don''t understand: Let''s say I want to make a sprite move on some blank surface... I need to render this blank surface? I mean, I must load a blank bitmap (background: black) on my surface, and then do whatever I want with the sprite... right? I can''t declare my surface to Nothing to have it blank huh? Thanks TeraZen, Last of the Returners

Share this post

Link to post
Share on other sites
you can use this code to fill a surface with one colour:

DDBLTFX ddbltfx;

/* Set size of structure */
ddbltfx.dwSize = sizeof( ddbltfx );
/* Set fill colour to specified colour */
ddbltfx.dwFillColor = dwColour;

/* Do Fill */
/* First parameter is a pointer to a RECT specifying want
portion of the surface to fill. NULL means all of it */
dderval = lpDDSurface->Blt( NULL, NULL, NULL, DDBLT_COLORFILL | DDBLT_WAIT, &ddbltfx );

The price of intelligence is stupidity

Edited by - gav on January 10, 2002 3:35:23 PM

Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!