Quote:Original post by remigius
Reconstructing the world matrix each frame may sound computationally expensive, but it shouldn't be even a blip on the performance radar. FWIW, I always reconstruct the world matrix each frame for each object and haven't run into any issues with that. If you'd really want to, you could only update the world matrix when something (pos/scale/rot) changes, but at some point you'll want your objects moving along smoothly and you'll need to update it practically every frame anyway. To put it into perspective, if you should move on to animation/skinning, you'll be constructing and setting tons of matrices each frame and this is nothing to worry about.
Cheers. That was my main problem - that I had no real idea how many of these construction/multiplication operations were done per object per frame in a real application.
Quote:Original post by remigius
From here you can construct your world matrix and/or change the various seperate transforms as needed without having to decompose the matrix (which as I recall is quite a bit more expensive than constructing one) and you don't have to worry about redundant transforms being 'in sync'. It may help to realize the quaternion is a robust presentation for expessing any rotations, not just some gimmick to do interpolations. If you want to set a new orientation, simply construct a quaternion from axis angle or euler and set that on the object (or of course slerp to the new target rotation). That way all internal rotation information is uniformly stored as quaternions and you can convert back and forth as needed.
This is pretty much what I was doing...
How does incrementing the orientation about a specific axis work? Do you create the incrementation rotation and compose it with the current orientation? Again all this seems like a lot of operations!