PDA

View Full Version : Image rotation and nearest neighbour lossiness levels.


UrbanFuturistic
09-22-2008, 04:40 PM
Just working on some image rotation stuff whereby I set the corners, bresenham the edges and designate ST co-ords per pixel then go leftmost to rightmost pixel to draw (not actually scanline).

Trying to find any literature on this kind of thing is a pain and I'm not entirely happy with the results, I'm using an image with different colours for each edge and corner to check for loss at the edges and while just an outline draws these fine (now) the full draw tends to double the thickness of some edges while often almost eliminating whichever is the bottom line at the time.

I suspect I know why this is but I'm hoping someone's got an elegant solution (or at least a best solution) before I throw in some poorly thought out hack. Of course, if the only solution is over-sampling or bilinear interpolation, so be it. Otherwise, if anyone can point me in the direction of something relevant to good nearest neighbour transformation I'll be a happy man.

CGTalk Moderation
09-22-2008, 04:40 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.