Dismiss Notice
Join Physics Forums Today!
The friendliest, high quality science and math community on the planet! Everyone who loves science is here!

Rotating an image with MATLAB

  1. Aug 26, 2010 #1

    I am working on a MATLAB assignment and I stuck in rotating image,
    I got a code that allocates starting and ending points in matrix I got, works with no difficulties. (which means this code allows me to ignore the white(255) points and get he actual size of image, that is a rectangle or a square)

    My problem is I needed to find maximum dimension of this picture when rotated, so that I will expand all of my rotations to maximum rotation size. I can't obtain that so simply.

    I got a solution (probably incorrect) which is:

    think that the image I got is a rectangle with width:a, length:b,
    when I rotate to 45degrees I get the maximum size, so that with simple Pythagorean theorem we can say that one side comes from a is a*sqrt(2) and other is b*sqrt(2), then maximum size of my image when rotated should be a square, with one side equals to (a+b)*sqrt(2), which gives an incorrect result.

    Can you help me out?
  2. jcsd
Know someone interested in this topic? Share this thread via Reddit, Google+, Twitter, or Facebook

Can you offer guidance or do you also need help?
Draft saved Draft deleted

Similar Threads - Rotating image MATLAB Date
Mathematica Rotation of 3D Plot using Euler angles Feb 15, 2016
Rotate the wheel to a specific point Nov 20, 2012
MATLAB Rotate Around X-Axis Oct 6, 2010
Mathematica- Rotating a 2D plot into a 3D plot Sep 8, 2010
Rotating images in matlab Mar 24, 2005