当前位置:网站首页>qt 64位静态版本显示gif
qt 64位静态版本显示gif
2022-04-23 11:15:00 【还债大湿兄】
本文章适合64位qt静态版本显示gif 共分4步
1.添加宏 Q_IMPORT_PLUGIN(QGifPlugin)
int main(int argc, char *argv[])
{
Q_IMPORT_PLUGIN(QWindowsIntegrationPlugin);
Q_IMPORT_PLUGIN(QGifPlugin)
//Q_IMPORT_PLUGIN(QICNSPlugin)
//Q_IMPORT_PLUGIN(QMinimalIntegrationPlugin);
QApplication a(argc, argv);
QTGuitest w;
w.show();
return a.exec();
}
2.查看静态版本是否支持gif
查看编译的版本下:Qt\Qt5.8.0_static\plugins\imageformats 是否存在qgifd.lib qgif.lib库
3.存在的话就引入到工程如果是用vs qt就加在 附加依赖库 :qgifd.lib 我这用的是debug版本的
4.为了省事,把这些库放入编译和运行文件夹,我全上了,你们可以只加一个地方啊,也可以加入库头文件目录索引
5.添加一个label
QMovie *movie = new QMovie("D:/500.gif");
ui.label_9->setMovie(movie);
movie->start();
6.成功了,没有 困难的工作,只有勇敢的狗狗

版权声明
本文为[还债大湿兄]所创,转载请带上原文链接,感谢
https://blog.csdn.net/qq_30377315/article/details/118329516
边栏推荐
- @Valid, @ validated learning notes
- ConstraintLayout布局
- Visualization Road (10) detailed explanation of segmentation canvas function
- 闹钟场景识别
- PlatoFarm推出正式版游戏经济模型的特点分析
- How to bind a process to a specified CPU
- Introduction to neo4j authoritative guide, recommended by Qiu Bojun, Zhou Hongxiang, Hu Xiaofeng, Zhou Tao and other celebrities
- Learn go language 0x06: Fibonacci closure exercise code in go language journey
- MySQL索引优化之分页探索详细介绍
- MBA - day5 mathématiques - Questions d'application - Questions d'ingénierie
猜你喜欢

精彩回顾|「源」来如此 第六期 - 开源经济与产业投资

年度最尴尬的社死瞬间,是Siri给的

比深度学习更值得信赖的模型ART

Detailed explanation of typora Grammar (I)

Google Earth engine (GEE) - scale up the original image (taking Hainan as an example)

进程间通信 -- 消息队列

Learn go language 0x04: Code of exercises sliced in go language journey

Visual Road (XII) detailed explanation of collection class

C语言之结构体(进阶篇)

Jupyter lab top ten high productivity plug-ins
随机推荐
Learn go language 0x05: the exercise code of map in go language journey
Oracle连通性测试小工具
MySQL索引优化之分页探索详细介绍
Visualization Road (11) detailed explanation of Matplotlib color
About the three commonly used auxiliary classes of JUC
Source insight 4.0 FAQs
Detailed explanation of writing sequence and execution sequence of MySQL series SQL query statements
比深度学习更值得信赖的模型ART
Cumcm 2021 - B: préparation d'oléfines C4 par couplage éthanol (2)
Explain in detail the pitfalls encountered in DTS due to the time zone problems of timestamp and datetime in MySQL
Analysis on the characteristics of the official game economic model launched by platoffarm
详解MySQL中timestamp和datetime时区问题导致做DTS遇到的坑
采用百度飞桨EasyDL完成指定目标识别
Typora operation skill description (I) md
学习网站资料
如何使用JDBC CallableStatement.wasNull()方法调用来查看最后一个OUT参数的值是否为 SQL NULL
Promise details
关于JUC三大常用辅助类
Implementation of partition table of existing data table by MySQL
MySQL数据库事务transaction示例讲解教程