Einzelnen Beitrag anzeigen

Benutzerbild von turboPASCAL
turboPASCAL

Registriert seit: 8. Mai 2005
Ort: Sondershausen
4.274 Beiträge
 
Delphi 6 Personal
 
#1

nonVCL - Bitmap in Bitmap kopieren

  Alt 25. Sep 2005, 11:00
Hi,

wie kann man ein Bitmap in ein anderes kopieren ? Diese Procedure zeichnet nur darüber:

Delphi-Quellcode:
procedure SetBitmap(hWnd: HWND);
begin
  h_DC := GetDC(GetDlgItem(hwnd, IDC_IMG1));

  hBitmapDC := CreateCompatibleDC(h_DC);
  hOldBitmap := SelectObject(hBitmapDC, Bitmap);

  BitBlt(h_DC, 0, 0, 32, 32, hBitmapDC, 0, 0, SRCCOPY);
                                            
  SelectObject(hBitmapDC, hOldBitmap);
  DeleteDC(hBitmapDC);
  ReleaseDC(hwnd, h_DC);
end;
Ich möchte in einem Dialog enth. Bitmap mein eigenes einsetzen.

VCL:ImageX.Picture.Assign(MyBitmap);
Matti
Meine Software-Projekte - Homepage - Grüße vom Rüsselmops -Mops Mopser
  Mit Zitat antworten Zitat