The collission detection doesn't need much extra time, because those
bounding things work really fast.
In fact I created those boundbox animations for testing purposes.
As you could see those boxes have different colors.
The color of a box shows if there are collissions between atoms inside the
box or between atoms of that box and atoms of a neighbor box.
(There are 26 neighbor boxes. Just check the first 13 of those neighbors,
otherwise you'll check the same collissions twice and would be a waste of
cycles.)
The colors of the boxes:
- blue: no collissions
- red: collissions between directly connected atoms --> ignore
- yellow: collissions --> add springs to push atoms apart.
Post a reply to this message
|