Browse Source

Default alpha compression to true

pull/1971/head
Brian Popow 4 years ago
parent
commit
d398ae7445
  1. 1
      src/ImageSharp/Formats/Webp/IWebpEncoderOptions.cs
  2. 2
      src/ImageSharp/Formats/Webp/WebpEncoder.cs
  3. 1
      src/ImageSharp/Formats/Webp/WebpEncoderCore.cs

1
src/ImageSharp/Formats/Webp/IWebpEncoderOptions.cs

@ -31,6 +31,7 @@ namespace SixLabors.ImageSharp.Formats.Webp
/// <summary>
/// Gets a value indicating whether the alpha plane should be compressed with Webp lossless format.
/// Defaults to true.
/// </summary>
bool UseAlphaCompression { get; }

2
src/ImageSharp/Formats/Webp/WebpEncoder.cs

@ -24,7 +24,7 @@ namespace SixLabors.ImageSharp.Formats.Webp
public WebpEncodingMethod Method { get; set; } = WebpEncodingMethod.Default;
/// <inheritdoc/>
public bool UseAlphaCompression { get; set; }
public bool UseAlphaCompression { get; set; } = true;
/// <inheritdoc/>
public int EntropyPasses { get; set; } = 1;

1
src/ImageSharp/Formats/Webp/WebpEncoderCore.cs

@ -23,6 +23,7 @@ namespace SixLabors.ImageSharp.Formats.Webp
/// <summary>
/// Indicating whether the alpha plane should be compressed with Webp lossless format.
/// Defaults to true.
/// </summary>
private readonly bool alphaCompression;

Loading…
Cancel
Save