rotating picture

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
adelina
Posts: 18
Joined: 2011-08-03T04:01:45-07:00
Authentication code: 8675308
Contact:

rotating picture

Post by adelina »

How do i found ,using a code in vbscript, if a picture is rotated and how many degrees is rotated?
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia
Contact:

Re: rotating picture

Post by anthony »

At this time determining rotation of an image is not a built in for Imagemagick. Though a UNIX shell script by Fred Weinhaus can determine this by one means.

There is a operation to unrotate -deskew a very slightly rotated image. By again Fred has another UNIX shell script that uses a different technique to deskew images with larger rotations.

Fred's ImageMagick Scripts
http://www.fmwconcepts.com/imagemagick/

These all depend on looking for the rectangular area of an image on a plain colors background image. For a skewed text image on a white background a completely different technique (looking for the angle of text lines) is needed.
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA
Contact:

Re: rotating picture

Post by fmw42 »

Does not the EXIF info in the file tell whether the image is rotated by 90 degree increments (so that IM can do an auto-orient. see http://www.imagemagick.org/script/comma ... uto-orient

If you are trying to determine the rotation so that you can unrotate the picture, see my unix bash script, unrotate at the link below.
Post Reply

Who is online

Users browsing this forum: Bing [Bot] and 24 guests