Question : affine transformation help

Hi,

I'm trying to rotate a set of points and someone told me to use affine transformation but I can't find any example or tutorial in vb.net or C#. Any help would be appreciated.

Answer : affine transformation help

This is a good tutorial on how to rotate an image if you know the angle:
http://www.switchonthecode.com/tutorials/csharp-tutorial-image-editing-rotate

To find out the angle, you may tell the user to click at the two end points (x1,y1) & (x2,y2) for one of the horizontal bars and the angle is calculated like so:

1:
2:
double angleInRadians = Math.Atan(y2-y1,x2-x1);
double angleInDegrees = angleInRadians / Math.PI * 180.0f;
Random Solutions  
 
programming4us programming4us