Thema: Delphi GIF in TImage

Einzelnen Beitrag anzeigen

Klaus01

Registriert seit: 30. Nov 2005
Ort: München
5.755 Beiträge
 
Delphi 10.4 Sydney
 
#12

Re: GIF in TImage

  Alt 10. Mai 2006, 15:12
schau mal ob es so geht, ansosten stelle ich heute Abend noch was ein,
habe noch ein Beispiel zuhause.

Delphi-Quellcode:
begin
  gif := TGIFImage.Create;
  gif.LoadFromFile('c:\giftest.gif');
  gif.Paint(Canvas,Form1.ClientRect,[goDirectDraw]);
end;



begin
  gif.Free;
end;
HowTo aus der FAQ:
Zitat:
How do you use the GifImage unit?


Simply add the GifImage unit to one the uses clauses in your program.
Then you can load GIF files into a TImage component the same way you load BMP files.

uses
GifImage;

procedure TForm1.Button1Click(Sender: TObject);
begin
Image.Picture.LoadFromFile('C:\SomeDir\SomeFile.gi f');
end;

-----

How to display animated GIF picture on the form?


Put GifImage in your uses clause in the program.
Then you can use Delphi's TImage component to load animated gif pictures.

-----
Die FAQ -> http://finn.mobilixnet.dk/delphi/gif-faq.txt

Grüße
Klaus
Klaus
  Mit Zitat antworten Zitat