I got quaternions working correctly now, but the code seems awfully inefficient, even after I cleaned it up quite a bit.

What it does:
It accepts an amount to change a rotation on the x,y, or z axis. It then generates a temporary quaternion which represents just the new rotation. The temp quaternion is multiplied by the quaternion representing the cumulative effect of all the rotations on every axis. Then a rotation matrix is built from the temp quaternion to rotate the axes, and the axes are rotated with this matrix. (This keeps all the axes in object space) Anyway, it just seems like a lot of computation for each and every rotation. Can some people have a look at my transformation class and see if you can think of a better way to do that?