javascript - How to check if two convex polyhedrons intersect with each other in Three.js? -


i'm working on problem need randomly generate , put convex polyhedrons cube/cylinder container @ randomly chosen points without overlapping. i'm using graphic output.

a demo.

while putting polyhedron, how check whether intersects other polyhedrons?

the convex polyhedron involved tetrahedron or hexahedron , constructed using three.convexgeometry. need precise check, bounding box not enough, use make sure 2 polyhedrons not intersected.

i've done lot research , found many complicated theories , methods, need boolean result tells if there exists intersection between 2 convex polyhedrons. sat (separating axis theorem) in 3d enough, three.js doesn't seem capable of doing this. can tell me how kind of check in simple way or explain how sat in 3d?

you can take @ http://www.realtimerendering.com/intersections.html. though site 2011 intersection algorithms have not changed in last years. demo seems once polyhedrons placed in cube, don't move. sat algorithm not best solution used moving polyhedra.


Comments

Popular posts from this blog

asp.net mvc - SSO between MVCForum and Umbraco7 -

Python Tkinter keyboard using bind -

ubuntu - Selenium Node Not Connecting to Hub, Not Opening Port -