-
-
Notifications
You must be signed in to change notification settings - Fork 886
Closed
Labels
Description
Prerequisites
- I have written a descriptive issue title
- I have verified that I am running the latest version of ImageSharp
- I have verified if the problem exist in both
DEBUGandRELEASEmode - I have searched open and closed issues to ensure it has not already been reported
ImageSharp version
2.1.3
Other ImageSharp packages and versions
Environment (Operating system, version and so on)
x86-64 Win11
.NET Framework version
.NET 6.0
Description
Webp with lossy conversion weighs more than lossless regardless of quality used.
Steps to Reproduce
using SixLabors.ImageSharp;
var image = SixLabors.ImageSharp.Image.Load("startFile.png");
image.Save("outLossless.webp", new SixLabors.ImageSharp.Formats.Webp.WebpEncoder
{
FileFormat = SixLabors.ImageSharp.Formats.Webp.WebpFileFormatType.Lossless
});
image.Save("outLosssy90.webp", new SixLabors.ImageSharp.Formats.Webp.WebpEncoder
{
FileFormat = SixLabors.ImageSharp.Formats.Webp.WebpFileFormatType.Lossy,
Quality = 90,
});
image.Save("outLosssy80.webp", new SixLabors.ImageSharp.Formats.Webp.WebpEncoder
{
FileFormat = SixLabors.ImageSharp.Formats.Webp.WebpFileFormatType.Lossy,
Quality = 80,
});
image.Save("outLosssy50.webp", new SixLabors.ImageSharp.Formats.Webp.WebpEncoder
{
FileFormat = SixLabors.ImageSharp.Formats.Webp.WebpFileFormatType.Lossy,
Quality = 50,
});
image.Save("outLosssy10+Alpha.webp", new SixLabors.ImageSharp.Formats.Webp.WebpEncoder
{
FileFormat = SixLabors.ImageSharp.Formats.Webp.WebpFileFormatType.Lossy,
UseAlphaCompression = true,
Quality = 10,
});
image.Dispose();Images
Result images:
test.zip
JimBobSquarePants

