Einzelnen Beitrag anzeigen

bernhard_LA

Registriert seit: 8. Jun 2009
Ort: Bayern
1.123 Beiträge
 
Delphi 11 Alexandria
 
#8

AW: physikalische Kopie einer Bitmap

  Alt 10. Feb 2020, 15:40
d.h. eine stabile Copyfunktion , ich will nachher zwei physikalische Bitmaps haben geht dann so


Delphi-Quellcode:
procedure CLoneBitmaps ( Bitmap1, Bitmap2 : TBitmap);

begin

SR := Rect(0,0,Bitmap1.Width,Bitmap1.Height);
DR := Rect(0,0,Bitmap2.Width,Bitmap2.Height);

Bitmap2.Canvas.Lock;
Bitmap2.Canvas.CopyRect(DR,Bitmap1.Canvas,SR);
Bitmap2.Canvas.Unlock;

end;

ist dies der richtige Weg ?
  Mit Zitat antworten Zitat