An Anti Aliased Image Rotation Algorithm


Version Compatibility: Visual Basic 6

More information:
An Anti Aliased Image Rotation Algorithm that uses Geometry to weigh pixels A pixel is a square, and should be treated as such. Explanation: Instead of trying to map pixels from the destination bitmap to the source bitmap, my algorithm uses geometry. Imagine that each pixel is a 1x1 square. My algorithm works by rotating each of the 1x1 squares from the source bitmap and overlapping them on another non-rotated bitmaps pixels. Because Pixels can only hold one discrete color, I have to find the area of overlap for each of the source pixels on each of the destination pixels. This takes more geometry than I care to explain but the code is there if you want to look at it and I added plenty of comments. When I have the area of overlap for each pixel, I have the ratio of how much representation that individual source pixel gets in each destination pixel.

Instructions: Click the link below to download the code. Select 'Save' from the IE popup dialog. Once downloaded, open the .zip file from your local drive using WinZip or a comparable program to view the contents.