![]() |
animiertes Gif Problem
Hallo
ich habe ein Problem mit gif Bild Wenn ich das Gif-Bild direkt von einem Ordner lade dann gehlt.
Delphi-Quellcode:
Aber wenn ich das Bild von Resource lade, dann sehe ich keine Animation. das Bild bleibt stehen
Image1.Picture.LoadFromFile('animation1.gif');
Delphi-Quellcode:
var
Res : TResourceStream; Bild : TGIFImage; begin Res := TResourceStream.Create(Hinstance, 'animation1.gif', PChar('BMP')); Bild := TGIFImage.Create; try Bild.LoadFromStream(res); finally Res.Free; end; Image1.Picture.Graphic := Bild; Bild.Free; end; |
Re: animiertes Gif Problem
Welche TGIFImage Komponente benutzt du denn? Delphi selbst kennt ja bis 2006 keine GIFs. Benutzt du GraphicEx?
|
Re: animiertes Gif Problem
Guck mal nach "TJvGifAnimator", das ist eine Komponente der JEDI VCL, und die kann man sich bekanntlich runterladen und installieren unter:
![]() |
Re: animiertes Gif Problem
Zitat:
|
Re: animiertes Gif Problem
Zitat:
ich have versucht ein gif in JvGIFAnimator1, leider bekomme ich immer einen fehler : invalid gif format ! |
Re: animiertes Gif Problem
Vermutlich wurde das Bild in der Resource nicht im Gif- sondern im Bmp-Format gespeichert.
Wenn keine Animation gespeichert ist, kann auch keine angezeigt werden. |
Re: animiertes Gif Problem
Zitat:
Delphi-Quellcode:
Res := TResourceStream.Create(Hinstance, 'animation1.gif', PChar('BMP'))
// oder Res := TResourceStream.Create(Hinstance, 'animation1.gif', PChar('GIF')) |
Re: animiertes Gif Problem
Es geht darum, in welchem Format die Grafik in der Ressource vorhanden ist. Es scheint kein GIF zu sein, daher die Fehlermeldung.
|
Re: animiertes Gif Problem
Zitat:
Es erscheint keine Fehlermeldung. Das Bild wird zwar von Ressource geladen aber bleibt stehen als das Bild nur aus einem bild besteht. |
Re: animiertes Gif Problem
Hast Du es mal aus der Ressource extrahiert und ausprobiert?
|
Alle Zeitangaben in WEZ +1. Es ist jetzt 02:29 Uhr. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
LinkBacks Enabled by vBSEO © 2011, Crawlability, Inc.
Delphi-PRAXiS (c) 2002 - 2023 by Daniel R. Wolf, 2024-2025 by Thomas Breitkreuz