当前位置:网站首页>记录一下Qt将少量图片输出为MP4的思路及注意事项
记录一下Qt将少量图片输出为MP4的思路及注意事项
2022-06-25 22:00:00 【北极熊的奋斗史】
1. 先使用库将所有图片保存为存储为gif图,存储到本地。库使用的刘典武大神的保存gif图库。可从下面地址下载到示例程序。示例程序。
2. 下载最新的ffmpeg运行程序,无需开发库,放到工程目录下。ffmpeg网址:Download FFmpeg
3. 使用QProess启动ffmpeg.exe进程,并附加参数:-f gif -i 源文件.gif -pix_fmt yuv420p 目标.mp4
即可将gif图片转为mp4。
注意:保存gif图片时,需设置:宽度必须是32的倍数,高度必须是2的倍数,否则会报错:width / height not divisible by 2。
采用先保存为gif,再转为MP4的办法是因为这样保存的速度快,效率高,不需要深入研究ffmpeg库的二次开发方法。
缺点是不能持续性的保存很大的视频,不能携带配套音频。
边栏推荐
- Windows安装Redis及简单使用
- How to use JMeter for interface testing
- 小程序绘制一个简单的饼图
- Live800在线客服系统:跨越时空做生意,从每次互动开始
- Basic operator
- 建立自己的网站(15)
- golang Make a list of intervals with sequential numbers
- Live800 online customer service system: do business across time and space, starting from each interaction
- 2. What is the geometric meaning of a vector multiplying its transpose?
- Applets - view and logic
猜你喜欢

Live800在线客服系统:跨越时空做生意,从每次互动开始

Set up your own website (15)

STM32开发板+机智云AIoT+家庭监测控制系统

Pit resolution encountered using East OCR (compile LAMS)

ES6学习-- LET

【无标题】打开一个项目连接,无法正常显示时,ping一下ip

ES6 - numerical extension and object extension

一位博士在华为的22年

LM small programmable controller software (based on CoDeSys) note XVII: PTO pulse function block

ES6 learning -- let
随机推荐
Jupiter notebook common shortcut keys
The wisdom of questioning? How to ask questions?
Unity technical manual - color in life cycle coloroverlifetime-- speed color colorbyspeed
【opencv450 samples】创建图像列表yaml
STM32开发板+机智云AIoT+家庭监测控制系统
Several optimization scenarios using like fuzzy retrieval in SQL
【EOSIO】EOS/WAX签名错误 is_canonical( c ): signature is not canonical 问题
Windows安装Redis及简单使用
头歌 第3关:使用线程锁(Lock)实现线程同步
Pit resolution encountered using East OCR (compile LAMS)
信息学奥赛一本通 1353:表达式括号匹配(stack) | 洛谷 P1739 表达式括号匹配
Multithreaded learning 1
Paper notes: multi tag learning MSWl
How to use JMeter for interface testing
22 years of a doctor in Huawei
一位博士在华为的22年
UE4\UE5 蓝图节点Delay与Retriggerable Delay的使用与区别
User interaction scanner usage Advanced Edition example
Ue4 Ue5 combine le plug - in de reconnaissance vocale de bureau pour la reconnaissance vocale
Unity technical manual - getKey and getaxis and getbutton