I implement the collision detection in my project so I have for each object an origin and max and min vertices so I can calculate the collision detection simply not accurate which is I want at that stage, but I may have many instanced objects which is only one object and is repeated many times in the vertex shader using the transformation matrices I passed to it. I do the collision test in the CPU so it doesn't know anything about the instances except the matrix array of them. can I apply the method I use for instanced objects?
Asked
Active
Viewed 373 times
2
-
2Of course, just transform your bounding box using each object's matrix. – Thomas Oct 02 '17 at 08:31
-
That makes sense, Thank you @Thomas , I just like to accept it as the correct answer – Mohamed Mousa El-Kheshen Oct 02 '17 at 08:38
-
Now you can. Glad it helped! – Thomas Oct 02 '17 at 14:26
1 Answers
2
Of course, just transform your bounding box using each object's matrix, then apply collision detection to the transformed boxes.

Thomas
- 174,939
- 50
- 355
- 478