调用了imglib.dll
procedure TMainFrm.ToolBRotaryClick(Sender: TObject);
var
pTemp: Pointer;
begin
Screen.Cursor := crHourGlass;
DeleteFile('c:/tmpsave.bmp');
ImageShow.Picture.SaveToFile('c:/tmpsave.bmp');
try
pTemp := ReadFileIntoDIB('c:/tmpsave.bmp');
except
Screen.Cursor := crDefault;
end;
if pTemp=nil then
begin
Screen.Cursor := crDefault;
exit;
end;
pTemp := RotateDIB(pTemp,90);
DeleteFile('c:/rotate.bmp');
WriteDIBToFile(pTemp,'c:/rotate.bmp',0);
ImageShow.Picture.LoadFromFile('c:/rotate.bmp');
Screen.Cursor := crDefault;
DIBFree(pTemp);
end;