Capsules that exactly overlap cause crash
Attached is a scene that will cause the crash.
Walking through the code in the debugger, it appears as though this code is the culprit:
axes.push_back((capsule1_endpoints[0] - capsule2_endpoints[0]).normalized());
axes.push_back((capsule1_endpoints[0] - capsule2_endpoints[1]).normalized());
axes.push_back((capsule1_endpoints[1] - capsule2_endpoints[0]).normalized());
axes.push_back((capsule1_endpoints[1] - capsule2_endpoints[1]).normalized());
If the capsule endpoints are the same, then that'll add 4 axes that are (0, 0).
We can't really handle an axis of (0, 0) so we should probably check that and do something special, but I'm not exactly sure what? In this case where the full capsule shape is exactly the same, we would want to count this as an overlap, but I could imagine other scenarios where they weren't exactly the same, but had exactly overlapping endpoints, which would also cause problems.
I think this is going to need some special casing like we did with overlapping cicles.