Sign in to follow this  
Krak

Using Trig in 3D Rotations?

Recommended Posts

Say I was going to rotate a 3D field...like a fighting arena, on its y axis. I know that the matrix for y rotations involves trigonomic functions...but for that to happen, you need a right triangle and a reference angle. My question is: if it's not clearly a triangle...and it's something like a character, or an entire level....how you do determine its reference angle, and the size and location of the triangle?

Share this post


Link to post
Share on other sites
Originally sine cosine and tangent were considered to be ratios of sides of right triangles, however now they are simply functions of angles.
The formula for the matrix you have rotates a point around the axis (0,1,0) by whatever angle you specify, just transform all the points in your model by the matrix and you should have the rotations you expect.

Share this post


Link to post
Share on other sites
Quote:
Original post by chowe6685
Originally sine cosine and tangent were considered to be ratios of sides of right triangles...
No. That's just how they're introduced. They're circular functions, because they define relationships between two radii and the intervening angle of a unit circle.

Other than that nitpick, chowe6685 is spot on.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this