Archived

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

Todd M Gillissie

direct draw alpha capabilities

Recommended Posts

I''m new at DirectX programming, but very experienced in graphics. I know that alpha-blending looks much better than simple color-keying, so I am looking for a good explanation of how to set up a DD surface''s alpha info and blitting to a surface (secondary surface probably) using that info. The SDK doesn''t seem to cover this subject. Todd M. Gillissie gillissie@yahoo.com

Share this post


Link to post
Share on other sites
Actually, I''m still wondering why there is a dwFlag called "dwAlphaBitDepth" if DirectDraw doesn''t support alpha-blending natively. What with the Alpha flag?

Todd M. Gillissie
gillissie@yahoo.com

Share this post


Link to post
Share on other sites
Directdraw has fields for a lot of things it doesn''t support, or only supports in certain situations... pixmap rotation for example.. I assume the alpha stuff is in there so It''ll all be ready if/when they add it in the future.

Share this post


Link to post
Share on other sites
I believe there's an article around here describing how you can use D3D to do alpha rendering in 2D (D3D supports Alpha channels)(I does mean that the requirements for a 2D application include a 3D graphics board )

You know, I never wanted to be a programmer...

Alexandre Moura

Edited by - alexmoura on October 10, 2000 5:00:16 AM

Share this post


Link to post
Share on other sites
Whaddoyaknow? I just implemented that exact tutorial from mrgamemaker.com this very evening! It''s a very good tutorial, and the results are excellent.

Once you start using D3D in your 2D apps there''s a wealth of things you can do - ie. flip surfaces horizontally (and vertically) so you only need half as much sprite data loaded into vidmem, billinear filtering so you can scale your sprites without blockiness... the list goes on! Man.... this is good!

One problem though! I just found out my video card only supports textures that are a power of two in dimension (ie. 64x128). And I thought I had a good card

Ahh yeah, Quantum! D3D is faster than MMX (on most cards anyway), and D3D (being the nice API that it is) supports MMX if the user doesn''t have a D3D compatible grapics card. Best of both worlds, IMHO

wise_guy

Share this post


Link to post
Share on other sites
well he specifically asked for directdraw alpha blending, i know of D3D alpha blending, but just wanted to give him that link

Share this post


Link to post
Share on other sites
quote:
Original post by A. Buza

Directdraw has fields for a lot of things it doesn''t support, or only supports in certain situations... pixmap rotation for example.. I assume the alpha stuff is in there so It''ll all be ready if/when they add it in the future.


None of it will be added to DirectDraw, actually. DirectX 8 (coming soon!) will integrate Direct3D and DirectDraw as one, so the DirectDraw interfaces as we know them will still be supported, but will no longer be updated. I''m not sure what DirectGraphics (?) will have as far as alpha-blending, but I guess we''ll find out in a month or so!

-Ironblayde
 Aeon Software

Share this post


Link to post
Share on other sites