Hi guys,
Thanks for all the pointers to root solvers and torus intersections.
I finally have some donuts spinning in a test program. I implemented
the method I said I was working on where the torus is represented as
2 vectors and 2 radii. I'm still writing it up, but it's quite fast
because half way to getting the quartic in t there are a couple early
exits - equivalent to testing against a bounding cylinder and slab.
The quartic is actually simpler to generate than to solve. For now I'm
using the GGems solver, but I'll still be writing something more optimal.
On the up side, I just dropped it in and it worked. This allowed me to
find bugs in MY code knowing that the root solver was working properly.
My donuts still need some things added to be fully integrated into the
rest of the code, but I won't keep asking how to handle them every couple
months any more. I'm still interested in general cubics & quartics...
Thanks all,
Paul