我正在使用以下代码压缩 WEBP 格式的图像:
bitmap.compress(Bitmap.CompressFormat.WEBP, 100, outputStream)
尽管我使用的是最高质量设置,但看起来图像不是压缩无损而是有损的。对应Android开发者文档,应该可以无损压缩WEBP-files:http: //developer.android.com/guide/appendix/media-formats.html http://developer.android.com/reference/android /graphics/Bitmap.CompressFormat.html
我正在使用 Android 4.4.2 Kitkat 的 Nexus 4 上执行此操作。此外,我在整个项目中使用最高的 SDK。
有没有人知道如何将位图保存为无损 WEBP 图像?