VCL 如何加载Gif图片和Png图片

加上头文件#include

<Vcl.Imaging.GIFImg.hpp>

#include <Vcl.Imaging.pngimage.hpp>

Image1->Picture->LoadFromFile("001.gif");
((TGIFImage*) Image1->Picture->Graphic)->Animate = true;//开始播放
((TGIFImage*) Image1->Picture->Graphic)->Animate = false;//停止播放

Image2->Picture->LoadFromFile("001.png");

posted @ 2016-01-14 15:35  一样菜  阅读(472)  评论(0编辑  收藏  举报