Einzelnen Beitrag anzeigen

ghubi01

Registriert seit: 18. Nov 2017
128 Beiträge
 
Delphi 12 Athens
 
#7

AW: Text auf ein Foto speichern

  Alt 14. Aug 2018, 10:59
Hallo,

so geht es auch:
Delphi-Quellcode:
procedure TForm2.TextToPicture;
var
  jp: TJPEGImage; //in der uses Anweidung Vcl.Imaging.Jpeg hinzufügen!
                   //Für D7 muss nur Jpeg hinzugefügt werden
begin
  jp:=TJPEGImage.Create;
  jp.LoadFromFile('C:\Users\...\Pictures\Bild1.JPG');
  Image1.Picture.Bitmap.Assign(jp);
  Image1.Picture.Bitmap.Canvas.TextOut(10,10,'Hallo');
  jp.Assign(Image1.Picture.Bitmap);
  jp.SaveToFile('C:\Users\..\Pictures\Bild2.JPG');
  jp.Free;
end;

Geändert von ghubi01 (14. Aug 2018 um 11:05 Uhr)
  Mit Zitat antworten Zitat