Where can I test rotation and translation matrices online to see how they affect an object?

Started by
0 comments, last by HappyCoder 8 years, 5 months ago

I have a character that is standing on a planet and when I press the left or right arrow keys I want the player to rotate around the planet while keeping his feet pointing toward the center of the planet. I also need to make him jump while moving.

I thought perhaps the best way to do this is to use matrices for the rotation and the translation. Does anyone know of a good website to go to that allows you to see how your matrix affects an object?

If not, can anyone help me figure out how to make this work?

Thanks!

Zach

Advertisement
Here is something in 2D that has lots of examples on transformations. The information here will translate very well to 3D. The biggest difference is 3D rotations are more complicated than 2d but hopefully this will help to wrap your mind around transformations.
http://www.html5rocks.com/en/tutorials/webgl/webgl_transforms/

When trying to figure out matrices remember that they are applied in order. Basic rotations always rotate around the origin. To rotate around an arbitrary point, you first move the arbitrary point to the origin, rotate, then move the point back.


rotationAroundPoint(point, rotation) = translate(point) * rotation * translate(-point)
My current game project Platform RPG

This topic is closed to new replies.

Advertisement