Jump to content
  • Advertisement
Sign in to follow this  
renman29

D3DXVec3Project result does not match texel's final screen coord

This topic is 3893 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

:( If I use a black texture with one red texel on it(so I can easily identify it), and texture a triangle on a polygon in 3D space - I notice that that texel does not appear at the same location if I manually transform the texel by pretending it's a vertex and using D3DXVec3Project. (Although it appears to work on regular vertices). The triangle is exactly the same dimensions on the texture map so I thought it would work. Maybe it has something to do with the way the texture is interpolated accross the polygon? They appear close but several pixels off most of the time. It's weird. Any ideas on how I can get the true screen position of any given texel? Any suggestions or comments are completely welcome. :)

Share this post


Link to post
Share on other sites
Advertisement
My guess would be that the problem is with your calculation of the texel's position in 3D space. I can't tell you how to calculate that, but if you post how you determine that, I may be able to find the problem there.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • 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!