How to calculate direction for D3DXIntersectTri function to find intersected point? And after getting the result in Distance how to get that coordinate(XYZ)?
1 Answer
4
-
\$\begingroup\$ Pls, Provide some simple example for it. I've googled by not found simple example. \$\endgroup\$Ganpat– Ganpat2013-04-08 06:50:18 +00:00Commented Apr 8, 2013 at 6:50
-
\$\begingroup\$ There will not be an example for every use case that you need. What part of the documentation is unclear? \$\endgroup\$Mokosha– Mokosha2013-04-08 14:37:13 +00:00Commented Apr 8, 2013 at 14:37
-
\$\begingroup\$ HOW TO CALCULATE DIRECTION? AND HOW TO GET NEW INTERSECTED POINT FROM DISTANCE RETURN BY THIS FUNCTION? \$\endgroup\$Ganpat– Ganpat2013-04-09 05:32:40 +00:00Commented Apr 9, 2013 at 5:32
-
\$\begingroup\$ If you pass vectors
panddas ray position and direction, the returned value in pDist will tell you how far along the ray the point of intersection is. You can retrieve it by computingp + pDist * dassumingdis normalized. Also, it would be good to refrain from using all caps in your posts. \$\endgroup\$Mokosha– Mokosha2013-04-09 20:14:06 +00:00Commented Apr 9, 2013 at 20:14