Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DXTK Collisions #53

Closed
Tonyx97 opened this issue Aug 17, 2016 · 1 comment
Closed

DXTK Collisions #53

Tonyx97 opened this issue Aug 17, 2016 · 1 comment
Labels

Comments

@Tonyx97
Copy link

Tonyx97 commented Aug 17, 2016

I just wanted to ask if it's possible to edit the actual code and get the point of collision for example of a triangle-ray test, I've been messing with the code but I couldn't get it, I'm a bit lost to find this...

@walbourn
Copy link
Member

I'm not sure what it is you are doing here. For most games, the best solution for collision is to use tests with bounding volumes (spheres, bounding boxes, oriented bounding boxes) as supported by DirectXMath.

Face-by-face triangle-level tests are very expensive, so it should be avoided as much as possible or at least have first-level collision using bounding volumes.

The main feature that is missing from DirectX Tool Kit to support triangle-level collision testing is that Model only puts the geometry data into GPU IBs/VBs. To support this kind of collision, it would need to return a std::vector of indices as well as a std::vector of positions (i.e. a collision mesh per this work item).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants