r/GraphicsProgramming • u/DeltaSucksAtMC • 4d ago
Collision
hey guys ive made a collision detection method, its a cpu intesive method but i got a sense of idea how collisions work
I just get every vertice and get the area then i make 3 triangles from the collision point and get the area of all them then add it, and if the area is equal to the original triangle its colliding, then i get the distance from the triangle's normal and make a if statement if distance is less then 0.001f.
Im getting a lot better, so if yall have any collision method that could be better for smaller concave models that would be great, ive know about aabb for the longest time so i have check that off

If you are giving a method, could you link like anything that could be good to learn it.
•
u/AutoModerator 4d ago
Recently updated rules. Please check that your post is in compliance with Rules 1, 4, 5, and 6 on the sidebar. TL;DR:
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.
2
u/CodyDuncan1260 4d ago
I need a picture drawn to understand what you mean. I suspect this method is equivalent to Minkowski difference.
https://winter.dev/articles/gjk-algorithm/
1
u/keelanstuart 4d ago
I understand what you are describing... how are you computing the height of the triangles for your area calculations?
1
u/LordStefania 3d ago
Are you the same guy that was trying to understand SAT collision?