Isn't there some interpolations involved to get exact values of elements in the matrix after rotation?
Main Topics
Browse All TopicsI need a c code that rotates 2D image and includes interpolations
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
Is this what you meant?
HOW DO I ROTATE A RASTER IMAGE BY AN ARBITRARY ANGLE?
The obvious but wrong method is to loop over the pixels in the source
image, transform each coordinate, and copy the pixel to the
destination. This is wrong because it leaves holes in the destination.
Instead, loop over the pixels in the destination image, apply the
*reverse* transformation to the coordinates, and copy that pixel from
the source. This method is quite general, and can be used for any
one-to-one 2-D mapping, not just rotation. You can add anti-aliasing
by doing sub-pixel sampling.
However, there is a much faster method, with antialising included,
which involves doing three shear operations. The method was originally
created for the IM Raster Toolkit; an implementation is also present
in PBMPLUS. Reference: A Fast Algorithm for Raster Rotation", by Alan
Paeth (awpaeth@watcgl.waterloo.e
(Vancouver). An article on the IM Raster Toolkit appears in the same
journal. An updated version of the rotation paper appears in "Graphics
Gems" under the original title.
Sorry, I thought you were asking question 1.01 from
http://www.faqs.org/faqs/g
for all points in the image
I now think you are asking question 3.01
The Paeth article no longer seems to be available on line,
you can get the Graphics Gems book, or there's a rotate.c in
http://www.leptonica.com/s
Business Accounts
Answer for Membership
by: ozoPosted on 2008-04-23 at 12:28:58ID: 21424408
what interpolations?