p; sp_w:integer;
sp_h :integer ;
nx:integer;
ny:integer);
var sc:TCanvas;
begin
sc:=TCanvas.Create;
try
sc.Handle:=GetDC(0);
bkcanvas.CopyRect( rect(0,0,sp_w, sp_h), sc,rect(nx, ny, nx+sp_w, ny+sp_h));
ReleaseDC(0, sc.handle);
finally
sc.free;
end;
end;
//透明拷贝图像函数
//静态调用API函数TransparentBlt
procedure tranbit(hdcDest:HDC;
nXOriginDest:integer;
nYOriginDest:integer;
nWidthDest:integer;
hHeightDest:integer;
hdcSrc:HDC;
nXOriginSrc:integer;
nYOriginSrc:integer;
nWidthSrc:integer;
nHeightSrc:integer;
crTransparent:UINT) ;
Var
LibHandle:HWND;//动态连接库句柄
//函数原型定义
DllName:Procedure(hdcDest:HDC;
nXOriginDest:integer;
nYOriginDest:integer;
nWidthDest:integer;
&