Java – collision detection using polygons
I wonder if anyone can give me an idea of how to implement the first class to define polygons and how to use this class to detect collisions between two polygons My java work on Android is more specific, although I can also use NDK for C / C + + I want to define my polygon. Do I only need an array of vertices?
When I do collision detection, I have read the information about separation axis theorem and GJK algorithm Is this the right way or does it make me too complicated Just try to start in the right direction thank you!
Solution
You sound quite new to this kind of thing, which may be a bigger problem you realize
I think you'd better first define the problem you're trying to solve, and then find a solution to the problem
Let me ask you some qualified questions:
Are you talking about 2D or 3D?
Is this a physical system?
Do you need to know where they intersect or where they intersect?
Do you need to do a Boolean operation on the shape (such as getting an intersection or union or something)?