|
검색결과 에러가 난다는 분은 몇분계셨는데 답글이 없어 다시 올립니다.
1.5버전부터 0.99버전 까지 테스트를 했는데 모두 에러가 나는군요. 코드는 다음과 같습니다.
(예전에 패패루님이 예제로 올려주신 거죠 ^_^)
#include <vcl.h>
#pragma hdrstop
#include "Unit1.h"
#include "G32_Transforms.hpp"
//---------------------------------------------------------------------------
#pragma package(smart_init)
#pragma link "G32_Image"
#pragma resource "*.dfm"
TForm1 *Form1;
//---------------------------------------------------------------------------
__fastcall TForm1::TForm1(TComponent* Owner)
: TForm(Owner)
{
}
//---------------------------------------------------------------------------
void __fastcall TForm1::TrackBar1Change(TObject *Sender)
{
int nWidth = ImgSrc->Width;
int nHeight = ImgSrc->Height;
ImgDst->Width = nWidth;
ImgDst->Height = nHeight;
TAffineTransformation *pT = new TAffineTransformation();
pT->SrcRect = FloatRect(0,0,(float)nWidth,(float)nHeight);
pT->Rotate(nWidth/2,nHeight/2,TrackBar1->Position);
ImgDst->BeginUpdate();
ImgDst->Bitmap->Clear();
Transform(ImgDst->Bitmap, ImgSrc->Bitmap, pT);
ImgDst->EndUpdate();
ImgDst->Repaint();
delete pT;
}
뭐 정 안돼면 비트맵회전 함수를 만들어야 겟지만 이미 게으름이 골수까지 사무친 터라... -_-;
|