Take the 2-minute tour ×
Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. It's 100% free, no registration required.

I have a similar question to this post, except that I don't know the rotation angle. I just need to put the upper left corner of the rotated rectangle to (Xmin, Ymin). How can I calculate the rotated position B from the original position A?

Illustration

share|improve this question
    
I suggest to put the rectangle in the middle of the image and actually rotate around the center of the rectangle. That would make calculations a lot easier (its only $(r\cos \alpha, r\sin \alpha)$ where $r$ is the distance from the center to the corner and $\alpha$ a respective angle to a corner. –  Peter Patzt Jul 2 '11 at 19:11
    
Oh, never thought of it. Thanks, will do! –  printemps Jul 2 '11 at 19:22
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.