Rotate example for Delphi

This example rotates the bitmap 45 degrees and redisplays the image. It resizes the bitmap to accommodate the rotation and uses blue as the fill color.

var
   sRet: Smallint;
   RasterProc: LEADRasterProcess;
begin
   RasterProc:= CreateComObject (CLASS_LEADRasterProcess) as LEADRasterProcess;
   RasterProc.Rotate (LEADRasterView1.Raster, 4500, ROTATE_RESIZE, RGB(0, 0, 255));
   LEADRasterView1.AutoSetRects:= True ;//Make sure the display rectangles are adjusted
   LEADRasterView1.ForceRepaint (sRet);
end;