Ellipsoid Creation and Rotation

1. May 14, 2008

Lazyshot

A little background first is that I'm currently a rising Sophomore at Winthrop University in South Carolina. I am a Computer Science and Mathematics Double Major. After finishing half-way through third semester calculus and dealing with 3-Dimensional space, vectors, planes, and surfaces, I really loved it. I decided to mold my two majors and create a video game engine, primarily First Person Shooter. Anyway, back to my question:

In order to detect bullet and model collision, I am going to create Hitboxes like counter-strike. But instead of rectangular prisms I was going to use Ellipsoids for a smoother body. Anyway, But in order for this to work properly I would have to create a torso, head, arms, and legs. Understandable. Now, I have no problem creating the initial ellipsoids, because the origins are all fixed relative to the torso's origin. The problem is about when I want to rotate the body.

Other information is that I have a unit vector representing the facing direction of the body.

Anyone have any suggestions. I'm getting so frustrated that I feel like scrapping the whole thing.

2. May 14, 2008

optrix

Could you express the ellipsoids in a spherical rather than cartesian co-ordinate system, and then parameterize the angles, so you have a parameterized function $$\psi(\theta,\varphi)=(2r\cos{\varphi}\cos{\theta}, 3r\cos{\varphi}\sin{\theta},\sin{\varphi})$$

Last edited: May 14, 2008
3. May 14, 2008

optrix

Well, for some reason, that maths didn't come out as I'd expected, maybe you can quote my post to see what I meant.