Jump to content
  • Advertisement
Sign in to follow this  
ankhd

can Somebody please help me with this Intersected Triangle

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

hey there, well the problem is that when I go to render the Vertex buffer that I put the selected Triangle returned from the D3DXIntersect function using the face member. It makes the triangle but its not in the same location that I clicked when it gets rendered. I apply the world transform for the sphere and it renders ok but the dam triange is in its own position and it's not the right size. What could be wrong is it that I need to normalize it or something. here is the code I use to fill the VB with the triangle data.
vThisTri = &v[iIntersection * 3];
iThisTri = &pIndices[3* pIntersection->dwFace];
        
// get vertices hit this should be the triangle
vThisTri[0] = pVertices[iThisTri[0]];
vThisTri[1] = pVertices[iThisTri[1]];
vThisTri[2] = pVertices[iThisTri[2]];


Share this post


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

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!