Alpha Blended Images in D3D7?

Started by
6 comments, last by MasterWorks 18 years, 3 months ago
In Direct3D 8 and 9, you can use DDS files to setting the alpha channel image for images to use txetures... I'm wondering is there anyway of doing this same thing in Direct3D 7? Yes I know that DirectX 7 is a bit outdated but I still use DirectDraw for some games, so on this latest project I'm combining the two for 3D effects on a 2D game.
Advertisement
ddraw doesnt support alpha blending at all. but u can still use d3d7.
You can use any format that provides an alpha channel (like TGA for example).

You can also manually add/create the alpha value in a texture surface.

Fruny: Ftagn! Ia! Ia! std::time_put_byname! Mglui naflftagn std::codecvt eY'ha-nthlei!,char,mbstate_t>

In a reply to Anonymous Poster, you most of have not read my post correctly, as for in it, I clearly said that I was wanting to know how to do something with Direct3D7, and then I was giving my reason to why.

Now the reply to Endurion, you mentioned that you can add/create alpha channels in a texture surface, how can I do this? I've never actually seen any documation on this, but any help is greatly appreciated.
Quote:Original post by digital_phantom
Now the reply to Endurion, you mentioned that you can add/create alpha channels in a texture surface, how can I do this? I've never actually seen any documation on this, but any help is greatly appreciated.


This is a sample in D3D8, but I think the relevant bit should be similar. Basically you can Lock the texture and write your own alpha channel. This can be done based on the image itself (as the sample does) or you could take it from another image.

Computed Alpha Channel
Stay Casual,KenDrunken Hyena
DrunkenHyena, Thanks, I have downloaded the source and exe, and I will study it and see if I can archive this in Direct3D7.
I'm using Visual Basic is the thing, and that tutorial isn't very valid in it because VB doesn't support memory addresses like C/C++ does.

As what Endurion said, I can use TGA, but I didn't know that DirectX 7 supported loading any image format besides BMP, if it does more besides BMP then what formats?
I use Visual Basic and while there's wrappers, etc. available to use DX7 stuff, you might want to consider using just Direct3D8 since it is properly supported. You can do all the 2D stuff you did with DDraw in D3D, and you can do it better if you choose... this may not be an option for you, don't know...

This topic is closed to new replies.

Advertisement