Sign in to follow this  
SHKiN

texkill and GeForce

Recommended Posts

Hi everybody! I'm doing alphatest on R16G16F via texkill: texld r0, t0, s0 ; load colormap sub r1, r0.a, c0.r ; c0.r contains alphaRef value mapped into [0..1] range texkill r1 ; kill pixel if its alpha is below alphaRef ... On all ATI's cards this works just fine, but on GeForceFX I see some strange and ugly picture - some tris are alphatested, but looks like texcoords are distorted, while others are completely opaque. Any help will be appreciated Thank you

Share this post


Link to post
Share on other sites
I'm not sure how loading an alpha value from a texture without an alpha channel in it is a good idea.

At a minimum, you have to check the spec to see what the correct behavior is supposed to be.

Even so, there are often driver bugs lurking in unusual uses of the api.

Hopefully that is just a typo.

Share this post


Link to post
Share on other sites
Sorry guys, i've mean that R16G16F is a rendertarget, source texture has alpha, of course =)

I've found that texkill behaviour on FX is very strange. RHW vertices are OK, but with untransformed I receive distorted texcords.

Same thing on REF =(

Already tried about 10 detonators =(

BTW, DX8.1 ps.1.4 works fine

Share this post


Link to post
Share on other sites
Finally I've got it!!!

def c1, 1, 1, 1, 1

...

mov r0.a, c1.r <==================== this line repairs everything!

mov oC0, r0

Thanks everybody for your replies!

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this