You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// version 2.88.9
bitmapSrc.ScalePixels(bitmapDst, SKFilterQuality.High);
skDataWebp = bitmapDst.Encode(SKEncodedImageFormat.Webp, 75); // convert to webp format
// version 3.116.1 - SKFilterQuality is obsolete
// use SKSamplingOptions variant equivalent to SKFilterQuality.High
SKSamplingOptions samplingOptions = new SKSamplingOptions(resampler: SKCubicResampler.Mitchell);
bitmapSrc.ScalePixels(bitmapDst, samplingOptions);
skDataWebp = bitmapDst.Encode(SKEncodedImageFormat.Webp, 75); // convert to webp format
Expected Behavior
The downsized image is expected to be of the same quality and size.
Actual Behavior
The downsized image is larger and of inferior quality.
Version of SkiaSharp
3.116.0 (Current)
Last Known Good Version of SkiaSharp
2.88.9 (Previous)
IDE / Editor
Visual Studio (Windows), Visual Studio Code (macOS)
Description
Bitmap downsizing using SKBitmap.ScalePixels in version 3.116.1 produces images of a larger size and of a lower quality compared to version 2.88.9
Original image (1440X720): https://ptdt.azureedge.net/data/test/large.png
Resized using v2.88.9 (480X240): https://ptdt.azureedge.net/data/test/small_v2.webp
Resized using v3.116.1 (480X240): https://ptdt.azureedge.net/data/test/small_v3.webp
Code
// version 2.88.9
bitmapSrc.ScalePixels(bitmapDst, SKFilterQuality.High);
skDataWebp = bitmapDst.Encode(SKEncodedImageFormat.Webp, 75); // convert to webp format
// version 3.116.1 - SKFilterQuality is obsolete
// use SKSamplingOptions variant equivalent to SKFilterQuality.High
SKSamplingOptions samplingOptions = new SKSamplingOptions(resampler: SKCubicResampler.Mitchell);
bitmapSrc.ScalePixels(bitmapDst, samplingOptions);
skDataWebp = bitmapDst.Encode(SKEncodedImageFormat.Webp, 75); // convert to webp format
Expected Behavior
The downsized image is expected to be of the same quality and size.
Actual Behavior
The downsized image is larger and of inferior quality.
Version of SkiaSharp
3.116.0 (Current)
Last Known Good Version of SkiaSharp
2.88.9 (Previous)
IDE / Editor
Visual Studio (Windows), Visual Studio Code (macOS)
Platform / Operating System
Windows, Mac Catalyst
Platform / Operating System Version
Windows 11 24H2, macOS 15.1.1
Devices
Desktop
Relevant Screenshots
Original image (1440X720): https://ptdt.azureedge.net/data/test/large.png
Resized using v2.88.9 (480X240): https://ptdt.azureedge.net/data/test/small_v2.webp
Resized using v3.116.1 (480X240): https://ptdt.azureedge.net/data/test/small_v3.webp
Relevant Log Output
Code of Conduct
The text was updated successfully, but these errors were encountered: