delphi图像复制
delphi图像复制
CopyRect(const Dest: TRect Canvas: TCanvas const Source: Trect)
其中参数,Dest为目的矩形,Canvas是源画布,Source为源矩形。
with SourceRect do
begin
Left := x1
Top := y1
Right := x2
Bottom := y2
end
with DestRect do
begin
Left := x11
Top := x12
Right := y11
Bottom := y12
end
ForeImage.Canvas.CopyRect(DestRect, BackImage.Canvas, SourceRect)
拷贝的时候Bottom 设置成10.
回答完毕,谢谢。。。