幾種 WebP 動態圖制作方法


1.RealWorld Paint

目前唯一有圖形用戶界面的 動態 webp 編輯器, 利用最新版本 libwebp v1.0.0 生成的有損動態圖是打不開.
這個有兩個版本, 推薦使用 2013.1, unstable 2016.1 版本無法打開有些動態 webp 文件.
RealWorld Paint also supports many standard image files like .jpg, .png, .bmp, .gif, .webp and more.
http://www.rw-designer.com/image-editor

2.ffmpeg ( 編譯時需要加 --enable-libwebp )
ffmpeg 編碼時兩個參數說明
-lossless boolean 啟用/禁用無損模式 缺省值是0
-qscale float 對於有損編碼,這將控制圖像質量,0到100.
對於無損編碼,這將控制更多壓縮工作量和時間。缺省值為75.

無損方式
ffmpeg -i 00.mp4 -vf scale=240:-1 -r 10 -lossless 1 -loop 0 -y 00-lossless.webp

有損方式
ffmpeg -i 00.mp4 -vf scale=240:-1 -r 10 -qscale 90 -loop 0 -y 00-loss90.webp

3.Animation conversion toolset
命令方式的轉換工具集.
The web-ani-tools.zip package contains four separate tools for converting GIF, PNG and WebP animations.
gif2webp - GIF -> WebP conversion.
gif2apng - GIF -> animated PNG conversion.
webp2apng - WebP -> animated PNG conversion.
webp2gif - WebP -> GIF conversion.
apng2webp - anmated PNG -> WebP conversion.
apng2gif - anmated PNG -> GIF conversion.
http://www.rw-designer.com/animation-tools

4.libwebp
library to encode and decode images in WebP format.
命令方式, 目前最新發布 v1.0.0, 開源代碼
有編碼 解碼 查看等命令.
https://github.com/webmproject/libwebp

在這里可下載編譯好的可執行程序

http://downloads.webmproject.org/releases/webp/index.html

下面是靜態編譯的無邊框模式查看工具, 按住鼠標左鍵可以移動, 單擊鼠標中鍵退出.

https://github.com/qq2225936589/vwebp/raw/master/vwebp.exe

備注: 動態 WebP 圖片 Chrome 版本32+ 才支持.

WebP qscale 90 602K                                                      GIF 741K


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM