alpha blend vs alpha test

You are an experienced programmer and have a problem with the engine, shaders, or advanced effects? Here you'll get answers.
No questions about C++ programming or topics which are answered in the tutorials!
Post Reply
zola
Posts: 52
Joined: Thu Jul 15, 2004 2:31 pm
Location: switzerland
Contact:

alpha blend vs alpha test

Post by zola »

Hi
I want to learn more about DirectX so I've been looking through the directx9 videodriver and found something that I don't understand.

when using Material irr::video::EMT_TRANSPARENT_ALPHA_CHANNEL
the renderstates for ALPHATEST and ALPHABLEND are enabled. Doesn't these two states exclude each other?

This is what I thought they do:

ALPHABLEND enables blending according to the texture and source alpha values. (depends on the chosen blend_func)

ALPHATEST set a threshold for alpha values, pixels with values beyond the threshold will not be painted. (depends on the chosen alpha_func)

I'm new to DX so if someone could please explain what this constelation does?

Thanks
Post Reply