diff --git a/src/ImageSharp/Formats/Webp/AlphaDecoder.cs b/src/ImageSharp/Formats/Webp/AlphaDecoder.cs
index ba27d9999e..c2a6a261f5 100644
--- a/src/ImageSharp/Formats/Webp/AlphaDecoder.cs
+++ b/src/ImageSharp/Formats/Webp/AlphaDecoder.cs
@@ -59,7 +59,7 @@ namespace SixLabors.ImageSharp.Formats.Webp
if (this.Compressed)
{
var bitReader = new Vp8LBitReader(data);
- this.LosslessDecoder = new WebPLosslessDecoder(bitReader, memoryAllocator, configuration);
+ this.LosslessDecoder = new WebpLosslessDecoder(bitReader, memoryAllocator, configuration);
this.LosslessDecoder.DecodeImageStream(this.Vp8LDec, width, height, true);
this.Use8BDecode = this.Vp8LDec.Transforms.Count > 0 && Is8BOptimizable(this.Vp8LDec.Metadata);
}
@@ -113,7 +113,7 @@ namespace SixLabors.ImageSharp.Formats.Webp
///
/// Gets the Vp8L decoder which is used to de compress the alpha channel, if needed.
///
- private WebPLosslessDecoder LosslessDecoder { get; }
+ private WebpLosslessDecoder LosslessDecoder { get; }
///
/// Gets a value indicating whether the decoding needs 1 byte per pixel for decoding.
@@ -260,7 +260,7 @@ namespace SixLabors.ImageSharp.Formats.Webp
// Extract alpha (which is stored in the green plane).
int pixelCount = width * numRowsToProcess;
- WebPLosslessDecoder.ApplyInverseTransforms(dec, input, this.memoryAllocator);
+ WebpLosslessDecoder.ApplyInverseTransforms(dec, input, this.memoryAllocator);
ExtractGreen(input, output, pixelCount);
this.AlphaApplyFilter(0, numRowsToProcess, output, width);
}
diff --git a/src/ImageSharp/Formats/Webp/BitWriter/BitWriterBase.cs b/src/ImageSharp/Formats/Webp/BitWriter/BitWriterBase.cs
index 10ec6201dd..41623f2878 100644
--- a/src/ImageSharp/Formats/Webp/BitWriter/BitWriterBase.cs
+++ b/src/ImageSharp/Formats/Webp/BitWriter/BitWriterBase.cs
@@ -85,7 +85,7 @@ namespace SixLabors.ImageSharp.Formats.Webp.BitWriter
stream.Write(WebpConstants.RiffFourCc);
BinaryPrimitives.WriteUInt32LittleEndian(buf, riffSize);
stream.Write(buf);
- stream.Write(WebpConstants.WebPHeader);
+ stream.Write(WebpConstants.WebpHeader);
}
///
diff --git a/src/ImageSharp/Formats/Webp/IWebpEncoderOptions.cs b/src/ImageSharp/Formats/Webp/IWebpEncoderOptions.cs
index a14921011d..4992f585d5 100644
--- a/src/ImageSharp/Formats/Webp/IWebpEncoderOptions.cs
+++ b/src/ImageSharp/Formats/Webp/IWebpEncoderOptions.cs
@@ -6,7 +6,7 @@ namespace SixLabors.ImageSharp.Formats.Webp
///
/// Configuration options for use during webp encoding.
///
- internal interface IWebPEncoderOptions
+ internal interface IWebpEncoderOptions
{
///
/// Gets a value indicating whether lossy compression should be used.
@@ -30,7 +30,7 @@ namespace SixLabors.ImageSharp.Formats.Webp
int Method { get; }
///
- /// Gets a value indicating whether the alpha plane should be compressed with WebP lossless format.
+ /// Gets a value indicating whether the alpha plane should be compressed with Webp lossless format.
///
bool UseAlphaCompression { get; }
diff --git a/src/ImageSharp/Formats/Webp/Lossless/WebpLosslessDecoder.cs b/src/ImageSharp/Formats/Webp/Lossless/WebpLosslessDecoder.cs
index 9382785176..9604160091 100644
--- a/src/ImageSharp/Formats/Webp/Lossless/WebpLosslessDecoder.cs
+++ b/src/ImageSharp/Formats/Webp/Lossless/WebpLosslessDecoder.cs
@@ -19,7 +19,7 @@ namespace SixLabors.ImageSharp.Formats.Webp.Lossless
/// The lossless specification can be found here:
/// https://developers.google.com/speed/webp/docs/webp_lossless_bitstream_specification
///
- internal sealed class WebPLosslessDecoder
+ internal sealed class WebpLosslessDecoder
{
///
/// A bit reader for reading lossless webp streams.
@@ -75,12 +75,12 @@ namespace SixLabors.ImageSharp.Formats.Webp.Lossless
};
///
- /// Initializes a new instance of the class.
+ /// Initializes a new instance of the class.
///
/// Bitreader to read from the stream.
/// Used for allocating memory during processing operations.
/// The configuration.
- public WebPLosslessDecoder(Vp8LBitReader bitReader, MemoryAllocator memoryAllocator, Configuration configuration)
+ public WebpLosslessDecoder(Vp8LBitReader bitReader, MemoryAllocator memoryAllocator, Configuration configuration)
{
this.bitReader = bitReader;
this.memoryAllocator = memoryAllocator;
@@ -675,7 +675,7 @@ namespace SixLabors.ImageSharp.Formats.Webp.Lossless
}
///
- /// A WebP lossless image can go through four different types of transformation before being entropy encoded.
+ /// A Webp lossless image can go through four different types of transformation before being entropy encoded.
/// This will reverse the transformations, if any are present.
///
/// The decoder holding the transformation infos.
diff --git a/src/ImageSharp/Formats/Webp/Lossy/WebpLossyDecoder.cs b/src/ImageSharp/Formats/Webp/Lossy/WebpLossyDecoder.cs
index 70383706b7..ebb0b0aa4a 100644
--- a/src/ImageSharp/Formats/Webp/Lossy/WebpLossyDecoder.cs
+++ b/src/ImageSharp/Formats/Webp/Lossy/WebpLossyDecoder.cs
@@ -17,7 +17,7 @@ namespace SixLabors.ImageSharp.Formats.Webp.Lossy
///
/// The lossy specification can be found here: https://tools.ietf.org/html/rfc6386
///
- internal sealed class WebPLossyDecoder
+ internal sealed class WebpLossyDecoder
{
///
/// A bit reader for reading lossy webp streams.
@@ -35,12 +35,12 @@ namespace SixLabors.ImageSharp.Formats.Webp.Lossy
private readonly Configuration configuration;
///
- /// Initializes a new instance of the class.
+ /// Initializes a new instance of the class.
///
/// Bitreader to read from the stream.
/// Used for allocating memory during processing operations.
/// The configuration.
- public WebPLossyDecoder(Vp8BitReader bitReader, MemoryAllocator memoryAllocator, Configuration configuration)
+ public WebpLossyDecoder(Vp8BitReader bitReader, MemoryAllocator memoryAllocator, Configuration configuration)
{
this.bitReader = bitReader;
this.memoryAllocator = memoryAllocator;
diff --git a/src/ImageSharp/Formats/Webp/Readme.md b/src/ImageSharp/Formats/Webp/Readme.md
index f3daead832..38c1cad9d2 100644
--- a/src/ImageSharp/Formats/Webp/Readme.md
+++ b/src/ImageSharp/Formats/Webp/Readme.md
@@ -1,10 +1,10 @@
-# WebP Format
+# Webp Format
Reference implementation, specification and stuff like that:
- [google webp introduction](https://developers.google.com/speed/webp)
-- [WebP Spec 1.0.3](https://chromium.googlesource.com/webm/libwebp/+/v1.0.3/doc/webp-container-spec.txt)
-- [WebP VP8 Spec, Lossy](http://tools.ietf.org/html/rfc6386)
-- [WebP VP8L Spec, Lossless](https://developers.google.com/speed/webp/docs/webp_lossless_bitstream_specification)
-- [WebP filefront](https://wiki.fileformat.com/image/webp/)
-- [WebP test data](https://github.com/webmproject/libwebp-test-data/)
+- [Webp Spec 1.0.3](https://chromium.googlesource.com/webm/libwebp/+/v1.0.3/doc/webp-container-spec.txt)
+- [Webp VP8 Spec, Lossy](http://tools.ietf.org/html/rfc6386)
+- [Webp VP8L Spec, Lossless](https://developers.google.com/speed/webp/docs/webp_lossless_bitstream_specification)
+- [Webp filefront](https://wiki.fileformat.com/image/webp/)
+- [Webp test data](https://github.com/webmproject/libwebp-test-data/)
diff --git a/src/ImageSharp/Formats/Webp/WebpAlphaCompressionMethod.cs b/src/ImageSharp/Formats/Webp/WebpAlphaCompressionMethod.cs
index 75af0b3098..8875a3c894 100644
--- a/src/ImageSharp/Formats/Webp/WebpAlphaCompressionMethod.cs
+++ b/src/ImageSharp/Formats/Webp/WebpAlphaCompressionMethod.cs
@@ -11,7 +11,7 @@ namespace SixLabors.ImageSharp.Formats.Webp
NoCompression = 0,
///
- /// Compressed using the WebP lossless format.
+ /// Compressed using the Webp lossless format.
///
WebpLosslessCompression = 1
}
diff --git a/src/ImageSharp/Formats/Webp/WebpChunkType.cs b/src/ImageSharp/Formats/Webp/WebpChunkType.cs
index add40f302f..be17b420c0 100644
--- a/src/ImageSharp/Formats/Webp/WebpChunkType.cs
+++ b/src/ImageSharp/Formats/Webp/WebpChunkType.cs
@@ -6,7 +6,7 @@ namespace SixLabors.ImageSharp.Formats.Webp
///
/// Contains a list of different webp chunk types.
///
- /// See WebP Container Specification for more details: https://developers.google.com/speed/webp/docs/riff_container
+ /// See Webp Container Specification for more details: https://developers.google.com/speed/webp/docs/riff_container
internal enum WebpChunkType : uint
{
///
diff --git a/src/ImageSharp/Formats/Webp/WebpConstants.cs b/src/ImageSharp/Formats/Webp/WebpConstants.cs
index 169bc5b7dc..fd46bde2b5 100644
--- a/src/ImageSharp/Formats/Webp/WebpConstants.cs
+++ b/src/ImageSharp/Formats/Webp/WebpConstants.cs
@@ -11,7 +11,7 @@ namespace SixLabors.ImageSharp.Formats.Webp
internal static class WebpConstants
{
///
- /// The list of file extensions that equate to WebP.
+ /// The list of file extensions that equate to Webp.
///
public static readonly IEnumerable FileExtensions = new[] { "webp" };
@@ -80,9 +80,9 @@ namespace SixLabors.ImageSharp.Formats.Webp
};
///
- /// The header bytes identifying a WebP.
+ /// The header bytes identifying a Webp.
///
- public static readonly byte[] WebPHeader =
+ public static readonly byte[] WebpHeader =
{
0x57, // W
0x45, // E
diff --git a/src/ImageSharp/Formats/Webp/WebpDecoderCore.cs b/src/ImageSharp/Formats/Webp/WebpDecoderCore.cs
index db55bcd957..4a5a15b1ca 100644
--- a/src/ImageSharp/Formats/Webp/WebpDecoderCore.cs
+++ b/src/ImageSharp/Formats/Webp/WebpDecoderCore.cs
@@ -97,12 +97,12 @@ namespace SixLabors.ImageSharp.Formats.Webp
Buffer2D pixels = image.GetRootFramePixelBuffer();
if (this.webImageInfo.IsLossless)
{
- var losslessDecoder = new WebPLosslessDecoder(this.webImageInfo.Vp8LBitReader, this.memoryAllocator, this.Configuration);
+ var losslessDecoder = new WebpLosslessDecoder(this.webImageInfo.Vp8LBitReader, this.memoryAllocator, this.Configuration);
losslessDecoder.Decode(pixels, image.Width, image.Height);
}
else
{
- var lossyDecoder = new WebPLossyDecoder(this.webImageInfo.Vp8BitReader, this.memoryAllocator, this.Configuration);
+ var lossyDecoder = new WebpLossyDecoder(this.webImageInfo.Vp8BitReader, this.memoryAllocator, this.Configuration);
lossyDecoder.Decode(pixels, image.Width, image.Height, this.webImageInfo);
}
@@ -502,7 +502,7 @@ namespace SixLabors.ImageSharp.Formats.Webp
return chunkType;
}
- throw new ImageFormatException("Invalid WebP data.");
+ throw new ImageFormatException("Invalid Webp data.");
}
///
@@ -518,7 +518,7 @@ namespace SixLabors.ImageSharp.Formats.Webp
return (chunkSize % 2 == 0) ? chunkSize : chunkSize + 1;
}
- throw new ImageFormatException("Invalid WebP data.");
+ throw new ImageFormatException("Invalid Webp data.");
}
///
diff --git a/src/ImageSharp/Formats/Webp/WebpEncoder.cs b/src/ImageSharp/Formats/Webp/WebpEncoder.cs
index fd213cba15..bb30e2512a 100644
--- a/src/ImageSharp/Formats/Webp/WebpEncoder.cs
+++ b/src/ImageSharp/Formats/Webp/WebpEncoder.cs
@@ -10,9 +10,9 @@ using SixLabors.ImageSharp.PixelFormats;
namespace SixLabors.ImageSharp.Formats.Webp
{
///
- /// Image encoder for writing an image to a stream in the WebP format.
+ /// Image encoder for writing an image to a stream in the Webp format.
///
- public sealed class WebpEncoder : IImageEncoder, IWebPEncoderOptions
+ public sealed class WebpEncoder : IImageEncoder, IWebpEncoderOptions
{
///
public bool Lossy { get; set; }
diff --git a/src/ImageSharp/Formats/Webp/WebpEncoderCore.cs b/src/ImageSharp/Formats/Webp/WebpEncoderCore.cs
index 5fe188c8dc..63f54f133d 100644
--- a/src/ImageSharp/Formats/Webp/WebpEncoderCore.cs
+++ b/src/ImageSharp/Formats/Webp/WebpEncoderCore.cs
@@ -12,7 +12,7 @@ using SixLabors.ImageSharp.PixelFormats;
namespace SixLabors.ImageSharp.Formats.Webp
{
///
- /// Image encoder for writing an image to a stream in the WebP format.
+ /// Image encoder for writing an image to a stream in the Webp format.
///
internal sealed class WebpEncoderCore : IImageEncoderInternals
{
@@ -23,7 +23,7 @@ namespace SixLabors.ImageSharp.Formats.Webp
///
/// TODO: not used at the moment.
- /// Indicating whether the alpha plane should be compressed with WebP lossless format.
+ /// Indicating whether the alpha plane should be compressed with Webp lossless format.
///
private readonly bool alphaCompression;
@@ -83,7 +83,7 @@ namespace SixLabors.ImageSharp.Formats.Webp
///
/// The encoder options.
/// The memory manager.
- public WebpEncoderCore(IWebPEncoderOptions options, MemoryAllocator memoryAllocator)
+ public WebpEncoderCore(IWebpEncoderOptions options, MemoryAllocator memoryAllocator)
{
this.memoryAllocator = memoryAllocator;
this.alphaCompression = options.UseAlphaCompression;
diff --git a/src/ImageSharp/Formats/Webp/WebpFormat.cs b/src/ImageSharp/Formats/Webp/WebpFormat.cs
index 6a23b90677..1f27c4d843 100644
--- a/src/ImageSharp/Formats/Webp/WebpFormat.cs
+++ b/src/ImageSharp/Formats/Webp/WebpFormat.cs
@@ -20,7 +20,7 @@ namespace SixLabors.ImageSharp.Formats.Webp
public static WebpFormat Instance { get; } = new WebpFormat();
///
- public string Name => "WebP";
+ public string Name => "Webp";
///
public string DefaultMimeType => "image/webp";
diff --git a/src/ImageSharp/Formats/Webp/WebpImageFormatDetector.cs b/src/ImageSharp/Formats/Webp/WebpImageFormatDetector.cs
index a5d7a8201f..4bb794f56f 100644
--- a/src/ImageSharp/Formats/Webp/WebpImageFormatDetector.cs
+++ b/src/ImageSharp/Formats/Webp/WebpImageFormatDetector.cs
@@ -6,7 +6,7 @@ using System;
namespace SixLabors.ImageSharp.Formats.Webp
{
///
- /// Detects WebP file headers.
+ /// Detects Webp file headers.
///
public sealed class WebpImageFormatDetector : IImageFormatDetector
{
@@ -16,7 +16,7 @@ namespace SixLabors.ImageSharp.Formats.Webp
///
public IImageFormat DetectFormat(ReadOnlySpan header) => this.IsSupportedFileFormat(header) ? WebpFormat.Instance : null;
- private bool IsSupportedFileFormat(ReadOnlySpan header) => header.Length >= this.HeaderSize && this.IsRiffContainer(header) && this.IsWebPFile(header);
+ private bool IsSupportedFileFormat(ReadOnlySpan header) => header.Length >= this.HeaderSize && this.IsRiffContainer(header) && this.IsWebpFile(header);
///
/// Checks, if the header starts with a valid RIFF FourCC.
@@ -30,6 +30,6 @@ namespace SixLabors.ImageSharp.Formats.Webp
///
/// The header bytes.
/// True, if its a webp file.
- private bool IsWebPFile(ReadOnlySpan header) => header.Slice(8, 4).SequenceEqual(WebpConstants.WebPHeader);
+ private bool IsWebpFile(ReadOnlySpan header) => header.Slice(8, 4).SequenceEqual(WebpConstants.WebpHeader);
}
}
diff --git a/src/ImageSharp/Formats/Webp/WebpMetadata.cs b/src/ImageSharp/Formats/Webp/WebpMetadata.cs
index 8144d79b59..001ff1fbb4 100644
--- a/src/ImageSharp/Formats/Webp/WebpMetadata.cs
+++ b/src/ImageSharp/Formats/Webp/WebpMetadata.cs
@@ -4,7 +4,7 @@
namespace SixLabors.ImageSharp.Formats.Webp
{
///
- /// Provides WebP specific metadata information for the image.
+ /// Provides Webp specific metadata information for the image.
///
public class WebpMetadata : IDeepCloneable
{
diff --git a/tests/ImageSharp.Benchmarks/Codecs/DecodeWebp.cs b/tests/ImageSharp.Benchmarks/Codecs/DecodeWebp.cs
index 98e1f86897..940fe08b1b 100644
--- a/tests/ImageSharp.Benchmarks/Codecs/DecodeWebp.cs
+++ b/tests/ImageSharp.Benchmarks/Codecs/DecodeWebp.cs
@@ -26,10 +26,10 @@ namespace SixLabors.ImageSharp.Benchmarks.Codecs
private string TestImageLosslessFullPath => Path.Combine(TestEnvironment.InputImagesDirectoryFullPath, this.TestImageLossless);
- [Params(TestImages.WebP.Lossy.Earth)]
+ [Params(TestImages.Webp.Lossy.Earth)]
public string TestImageLossy { get; set; }
- [Params(TestImages.WebP.Lossless.Earth)]
+ [Params(TestImages.Webp.Lossless.Earth)]
public string TestImageLossless { get; set; }
[GlobalSetup]
@@ -45,7 +45,7 @@ namespace SixLabors.ImageSharp.Benchmarks.Codecs
[Benchmark(Description = "Magick Lossy Webp")]
public int WebpLossyMagick()
{
- var settings = new MagickReadSettings { Format = MagickFormat.WebP };
+ var settings = new MagickReadSettings { Format = MagickFormat.Webp };
using var memoryStream = new MemoryStream(this.webpLossyBytes);
using var image = new MagickImage(memoryStream, settings);
return image.Width;
@@ -62,7 +62,7 @@ namespace SixLabors.ImageSharp.Benchmarks.Codecs
[Benchmark(Description = "Magick Lossless Webp")]
public int WebpLosslessMagick()
{
- var settings = new MagickReadSettings { Format = MagickFormat.WebP };
+ var settings = new MagickReadSettings { Format = MagickFormat.Webp };
using var memoryStream = new MemoryStream(this.webpLossyBytes);
using var image = new MagickImage(memoryStream, settings);
return image.Width;
@@ -88,22 +88,22 @@ namespace SixLabors.ImageSharp.Benchmarks.Codecs
IterationCount=3 LaunchCount=1 WarmupCount=3
| Method | Job | Runtime | TestImageLossy | TestImageLossless | Mean | Error | StdDev | Gen 0 | Gen 1 | Gen 2 | Allocated |
|--------------------------- |----------- |-------------- |---------------------- |------------------------- |-----------:|----------:|---------:|----------:|----------:|------:|------------:|
- | 'Magick Lossy Webp' | Job-IERNAB | .NET 4.7.2 | WebP/earth_lossy.webp | WebP/earth_lossless.webp | 105.8 ms | 6.28 ms | 0.34 ms | - | - | - | 17.65 KB |
- | 'ImageSharp Lossy Webp' | Job-IERNAB | .NET 4.7.2 | WebP/earth_lossy.webp | WebP/earth_lossless.webp | 1,145.0 ms | 110.82 ms | 6.07 ms | - | - | - | 2779.53 KB |
- | 'Magick Lossless Webp' | Job-IERNAB | .NET 4.7.2 | WebP/earth_lossy.webp | WebP/earth_lossless.webp | 145.9 ms | 8.55 ms | 0.47 ms | - | - | - | 18.05 KB |
- | 'ImageSharp Lossless Webp' | Job-IERNAB | .NET 4.7.2 | WebP/earth_lossy.webp | WebP/earth_lossless.webp | 1,694.1 ms | 55.09 ms | 3.02 ms | 4000.0000 | 1000.0000 | - | 30556.87 KB |
- | 'Magick Lossy Webp' | Job-IMRAGJ | .NET Core 2.1 | WebP/earth_lossy.webp | WebP/earth_lossless.webp | 105.7 ms | 1.89 ms | 0.10 ms | - | - | - | 15.75 KB |
- | 'ImageSharp Lossy Webp' | Job-IMRAGJ | .NET Core 2.1 | WebP/earth_lossy.webp | WebP/earth_lossless.webp | 741.6 ms | 21.45 ms | 1.18 ms | - | - | - | 2767.85 KB |
- | 'Magick Lossless Webp' | Job-IMRAGJ | .NET Core 2.1 | WebP/earth_lossy.webp | WebP/earth_lossless.webp | 146.1 ms | 9.52 ms | 0.52 ms | - | - | - | 16.54 KB |
- | 'ImageSharp Lossless Webp' | Job-IMRAGJ | .NET Core 2.1 | WebP/earth_lossy.webp | WebP/earth_lossless.webp | 522.5 ms | 21.15 ms | 1.16 ms | 4000.0000 | 1000.0000 | - | 22860.02 KB |
- | 'Magick Lossy Webp' | Job-NAASQX | .NET Core 3.1 | WebP/earth_lossy.webp | WebP/earth_lossless.webp | 105.9 ms | 5.34 ms | 0.29 ms | - | - | - | 15.45 KB |
- | 'ImageSharp Lossy Webp' | Job-NAASQX | .NET Core 3.1 | WebP/earth_lossy.webp | WebP/earth_lossless.webp | 748.8 ms | 290.47 ms | 15.92 ms | - | - | - | 2767.84 KB |
- | 'Magick Lossless Webp' | Job-NAASQX | .NET Core 3.1 | WebP/earth_lossy.webp | WebP/earth_lossless.webp | 146.1 ms | 1.14 ms | 0.06 ms | - | - | - | 15.9 KB |
- | 'ImageSharp Lossless Webp' | Job-NAASQX | .NET Core 3.1 | WebP/earth_lossy.webp | WebP/earth_lossless.webp | 480.7 ms | 25.25 ms | 1.38 ms | 4000.0000 | 1000.0000 | - | 22859.7 KB |
- | 'Magick Lossy Webp' | Job-GLNACU | .NET Core 5.0 | WebP/earth_lossy.webp | WebP/earth_lossless.webp | 105.7 ms | 4.71 ms | 0.26 ms | - | - | - | 15.48 KB |
- | 'ImageSharp Lossy Webp' | Job-GLNACU | .NET Core 5.0 | WebP/earth_lossy.webp | WebP/earth_lossless.webp | 645.7 ms | 61.00 ms | 3.34 ms | - | - | - | 2768.13 KB |
- | 'Magick Lossless Webp' | Job-GLNACU | .NET Core 5.0 | WebP/earth_lossy.webp | WebP/earth_lossless.webp | 146.5 ms | 18.63 ms | 1.02 ms | - | - | - | 15.8 KB |
- | 'ImageSharp Lossless Webp' | Job-GLNACU | .NET Core 5.0 | WebP/earth_lossy.webp | WebP/earth_lossless.webp | 306.7 ms | 32.31 ms | 1.77 ms | 4000.0000 | 1000.0000 | - | 22860.02 KB |
+ | 'Magick Lossy Webp' | Job-IERNAB | .NET 4.7.2 | Webp/earth_lossy.webp | Webp/earth_lossless.webp | 105.8 ms | 6.28 ms | 0.34 ms | - | - | - | 17.65 KB |
+ | 'ImageSharp Lossy Webp' | Job-IERNAB | .NET 4.7.2 | Webp/earth_lossy.webp | Webp/earth_lossless.webp | 1,145.0 ms | 110.82 ms | 6.07 ms | - | - | - | 2779.53 KB |
+ | 'Magick Lossless Webp' | Job-IERNAB | .NET 4.7.2 | Webp/earth_lossy.webp | Webp/earth_lossless.webp | 145.9 ms | 8.55 ms | 0.47 ms | - | - | - | 18.05 KB |
+ | 'ImageSharp Lossless Webp' | Job-IERNAB | .NET 4.7.2 | Webp/earth_lossy.webp | Webp/earth_lossless.webp | 1,694.1 ms | 55.09 ms | 3.02 ms | 4000.0000 | 1000.0000 | - | 30556.87 KB |
+ | 'Magick Lossy Webp' | Job-IMRAGJ | .NET Core 2.1 | Webp/earth_lossy.webp | Webp/earth_lossless.webp | 105.7 ms | 1.89 ms | 0.10 ms | - | - | - | 15.75 KB |
+ | 'ImageSharp Lossy Webp' | Job-IMRAGJ | .NET Core 2.1 | Webp/earth_lossy.webp | Webp/earth_lossless.webp | 741.6 ms | 21.45 ms | 1.18 ms | - | - | - | 2767.85 KB |
+ | 'Magick Lossless Webp' | Job-IMRAGJ | .NET Core 2.1 | Webp/earth_lossy.webp | Webp/earth_lossless.webp | 146.1 ms | 9.52 ms | 0.52 ms | - | - | - | 16.54 KB |
+ | 'ImageSharp Lossless Webp' | Job-IMRAGJ | .NET Core 2.1 | Webp/earth_lossy.webp | Webp/earth_lossless.webp | 522.5 ms | 21.15 ms | 1.16 ms | 4000.0000 | 1000.0000 | - | 22860.02 KB |
+ | 'Magick Lossy Webp' | Job-NAASQX | .NET Core 3.1 | Webp/earth_lossy.webp | Webp/earth_lossless.webp | 105.9 ms | 5.34 ms | 0.29 ms | - | - | - | 15.45 KB |
+ | 'ImageSharp Lossy Webp' | Job-NAASQX | .NET Core 3.1 | Webp/earth_lossy.webp | Webp/earth_lossless.webp | 748.8 ms | 290.47 ms | 15.92 ms | - | - | - | 2767.84 KB |
+ | 'Magick Lossless Webp' | Job-NAASQX | .NET Core 3.1 | Webp/earth_lossy.webp | Webp/earth_lossless.webp | 146.1 ms | 1.14 ms | 0.06 ms | - | - | - | 15.9 KB |
+ | 'ImageSharp Lossless Webp' | Job-NAASQX | .NET Core 3.1 | Webp/earth_lossy.webp | Webp/earth_lossless.webp | 480.7 ms | 25.25 ms | 1.38 ms | 4000.0000 | 1000.0000 | - | 22859.7 KB |
+ | 'Magick Lossy Webp' | Job-GLNACU | .NET Core 5.0 | Webp/earth_lossy.webp | Webp/earth_lossless.webp | 105.7 ms | 4.71 ms | 0.26 ms | - | - | - | 15.48 KB |
+ | 'ImageSharp Lossy Webp' | Job-GLNACU | .NET Core 5.0 | Webp/earth_lossy.webp | Webp/earth_lossless.webp | 645.7 ms | 61.00 ms | 3.34 ms | - | - | - | 2768.13 KB |
+ | 'Magick Lossless Webp' | Job-GLNACU | .NET Core 5.0 | Webp/earth_lossy.webp | Webp/earth_lossless.webp | 146.5 ms | 18.63 ms | 1.02 ms | - | - | - | 15.8 KB |
+ | 'ImageSharp Lossless Webp' | Job-GLNACU | .NET Core 5.0 | Webp/earth_lossy.webp | Webp/earth_lossless.webp | 306.7 ms | 32.31 ms | 1.77 ms | 4000.0000 | 1000.0000 | - | 22860.02 KB |
*/
}
}
diff --git a/tests/ImageSharp.Benchmarks/Codecs/EncodeWebp.cs b/tests/ImageSharp.Benchmarks/Codecs/EncodeWebp.cs
index 8f3869a529..5405fbc1bf 100644
--- a/tests/ImageSharp.Benchmarks/Codecs/EncodeWebp.cs
+++ b/tests/ImageSharp.Benchmarks/Codecs/EncodeWebp.cs
@@ -44,8 +44,8 @@ namespace SixLabors.ImageSharp.Benchmarks.Codecs
public void MagickWebpLossy()
{
using var memoryStream = new MemoryStream();
- this.webpMagick.Settings.SetDefine(MagickFormat.WebP, "lossless", false);
- this.webpMagick.Write(memoryStream, MagickFormat.WebP);
+ this.webpMagick.Settings.SetDefine(MagickFormat.Webp, "lossless", false);
+ this.webpMagick.Write(memoryStream, MagickFormat.Webp);
}
[Benchmark(Description = "ImageSharp Webp Lossy")]
@@ -62,8 +62,8 @@ namespace SixLabors.ImageSharp.Benchmarks.Codecs
public void MagickWebpLossless()
{
using var memoryStream = new MemoryStream();
- this.webpMagick.Settings.SetDefine(MagickFormat.WebP, "lossless", true);
- this.webpMagick.Write(memoryStream, MagickFormat.WebP);
+ this.webpMagick.Settings.SetDefine(MagickFormat.Webp, "lossless", true);
+ this.webpMagick.Write(memoryStream, MagickFormat.Webp);
}
[Benchmark(Description = "ImageSharp Webp Lossless")]
diff --git a/tests/ImageSharp.Tests/Formats/WebP/PredictorEncoderTests.cs b/tests/ImageSharp.Tests/Formats/WebP/PredictorEncoderTests.cs
index e63ca2feca..80d48d0caa 100644
--- a/tests/ImageSharp.Tests/Formats/WebP/PredictorEncoderTests.cs
+++ b/tests/ImageSharp.Tests/Formats/WebP/PredictorEncoderTests.cs
@@ -82,7 +82,7 @@ namespace SixLabors.ImageSharp.Tests.Formats.Webp
};
// Convert image pixels to bgra array.
- byte[] imgBytes = File.ReadAllBytes(TestImageFullPath(TestImages.WebP.Peak));
+ byte[] imgBytes = File.ReadAllBytes(TestImageFullPath(TestImages.Webp.Peak));
using var image = Image.Load(imgBytes);
uint[] bgra = ToBgra(image);
@@ -111,7 +111,7 @@ namespace SixLabors.ImageSharp.Tests.Formats.Webp
};
// Convert image pixels to bgra array.
- byte[] imgBytes = File.ReadAllBytes(TestImageFullPath(TestImages.WebP.Lossless.BikeSmall));
+ byte[] imgBytes = File.ReadAllBytes(TestImageFullPath(TestImages.Webp.Lossless.BikeSmall));
using var image = Image.Load(imgBytes, new WebpDecoder());
uint[] bgra = ToBgra(image);
diff --git a/tests/ImageSharp.Tests/Formats/WebP/WebpDecoderTests.cs b/tests/ImageSharp.Tests/Formats/WebP/WebpDecoderTests.cs
index 7d763c05a7..34fa72c63e 100644
--- a/tests/ImageSharp.Tests/Formats/WebP/WebpDecoderTests.cs
+++ b/tests/ImageSharp.Tests/Formats/WebP/WebpDecoderTests.cs
@@ -6,7 +6,7 @@ using SixLabors.ImageSharp.Formats.Webp;
using SixLabors.ImageSharp.PixelFormats;
using SixLabors.ImageSharp.Tests.TestUtilities.ReferenceCodecs;
using Xunit;
-using static SixLabors.ImageSharp.Tests.TestImages.WebP;
+using static SixLabors.ImageSharp.Tests.TestImages.Webp;
// ReSharper disable InconsistentNaming
namespace SixLabors.ImageSharp.Tests.Formats.Webp
diff --git a/tests/ImageSharp.Tests/Formats/WebP/WebpEncoderTests.cs b/tests/ImageSharp.Tests/Formats/WebP/WebpEncoderTests.cs
index 8374342e85..a72621241c 100644
--- a/tests/ImageSharp.Tests/Formats/WebP/WebpEncoderTests.cs
+++ b/tests/ImageSharp.Tests/Formats/WebP/WebpEncoderTests.cs
@@ -6,7 +6,7 @@ using SixLabors.ImageSharp.Formats.Webp;
using SixLabors.ImageSharp.PixelFormats;
using SixLabors.ImageSharp.Tests.TestUtilities.ImageComparison;
using Xunit;
-using static SixLabors.ImageSharp.Tests.TestImages.WebP;
+using static SixLabors.ImageSharp.Tests.TestImages.Webp;
namespace SixLabors.ImageSharp.Tests.Formats.Webp
{
diff --git a/tests/ImageSharp.Tests/Formats/WebP/WebpMetaDataTests.cs b/tests/ImageSharp.Tests/Formats/WebP/WebpMetaDataTests.cs
index 901da3dbd8..1b0dc3e3fc 100644
--- a/tests/ImageSharp.Tests/Formats/WebP/WebpMetaDataTests.cs
+++ b/tests/ImageSharp.Tests/Formats/WebP/WebpMetaDataTests.cs
@@ -16,10 +16,10 @@ namespace SixLabors.ImageSharp.Tests.Formats.Webp
private static WebpDecoder WebpDecoder => new WebpDecoder() { IgnoreMetadata = false };
[Theory]
- [WithFile(TestImages.WebP.Lossy.WithExif, PixelTypes.Rgba32, false)]
- [WithFile(TestImages.WebP.Lossy.WithExif, PixelTypes.Rgba32, true)]
- [WithFile(TestImages.WebP.Lossless.WithExif, PixelTypes.Rgba32, false)]
- [WithFile(TestImages.WebP.Lossless.WithExif, PixelTypes.Rgba32, true)]
+ [WithFile(TestImages.Webp.Lossy.WithExif, PixelTypes.Rgba32, false)]
+ [WithFile(TestImages.Webp.Lossy.WithExif, PixelTypes.Rgba32, true)]
+ [WithFile(TestImages.Webp.Lossless.WithExif, PixelTypes.Rgba32, false)]
+ [WithFile(TestImages.Webp.Lossless.WithExif, PixelTypes.Rgba32, true)]
public void IgnoreMetadata_ControlsWhetherExifIsParsed(TestImageProvider provider, bool ignoreMetadata)
where TPixel : unmanaged, IPixel
{
@@ -42,10 +42,10 @@ namespace SixLabors.ImageSharp.Tests.Formats.Webp
}
[Theory]
- [WithFile(TestImages.WebP.Lossy.WithIccp, PixelTypes.Rgba32, false)]
- [WithFile(TestImages.WebP.Lossy.WithIccp, PixelTypes.Rgba32, true)]
- [WithFile(TestImages.WebP.Lossless.WithIccp, PixelTypes.Rgba32, false)]
- [WithFile(TestImages.WebP.Lossless.WithIccp, PixelTypes.Rgba32, true)]
+ [WithFile(TestImages.Webp.Lossy.WithIccp, PixelTypes.Rgba32, false)]
+ [WithFile(TestImages.Webp.Lossy.WithIccp, PixelTypes.Rgba32, true)]
+ [WithFile(TestImages.Webp.Lossless.WithIccp, PixelTypes.Rgba32, false)]
+ [WithFile(TestImages.Webp.Lossless.WithIccp, PixelTypes.Rgba32, true)]
public void IgnoreMetadata_ControlsWhetherIccpIsParsed(TestImageProvider provider, bool ignoreMetadata)
where TPixel : unmanaged, IPixel
{
@@ -64,7 +64,7 @@ namespace SixLabors.ImageSharp.Tests.Formats.Webp
}
[Theory]
- [WithFile(TestImages.WebP.Lossy.WithExif, PixelTypes.Rgba32)]
+ [WithFile(TestImages.Webp.Lossy.WithExif, PixelTypes.Rgba32)]
public void EncodeLossyWebp_PreservesExif(TestImageProvider provider)
where TPixel : unmanaged, IPixel
{
@@ -85,7 +85,7 @@ namespace SixLabors.ImageSharp.Tests.Formats.Webp
}
[Theory]
- [WithFile(TestImages.WebP.Lossless.WithExif, PixelTypes.Rgba32)]
+ [WithFile(TestImages.Webp.Lossless.WithExif, PixelTypes.Rgba32)]
public void EncodeLosslessWebp_PreservesExif(TestImageProvider provider)
where TPixel : unmanaged, IPixel
{
diff --git a/tests/ImageSharp.Tests/Formats/WebP/YuvConversionTests.cs b/tests/ImageSharp.Tests/Formats/WebP/YuvConversionTests.cs
index 76657d66bc..65b4b987e3 100644
--- a/tests/ImageSharp.Tests/Formats/WebP/YuvConversionTests.cs
+++ b/tests/ImageSharp.Tests/Formats/WebP/YuvConversionTests.cs
@@ -14,7 +14,7 @@ namespace SixLabors.ImageSharp.Tests.Formats.Webp
public class YuvConversionTests
{
[Theory]
- [WithFile(TestImages.WebP.Yuv, PixelTypes.Rgba32)]
+ [WithFile(TestImages.Webp.Yuv, PixelTypes.Rgba32)]
public void ConvertRgbToYuv_Works(TestImageProvider provider)
where TPixel : unmanaged, IPixel
{
diff --git a/tests/ImageSharp.Tests/TestImages.cs b/tests/ImageSharp.Tests/TestImages.cs
index 90965b3527..a9af84f9b5 100644
--- a/tests/ImageSharp.Tests/TestImages.cs
+++ b/tests/ImageSharp.Tests/TestImages.cs
@@ -517,7 +517,7 @@ namespace SixLabors.ImageSharp.Tests
public const string NoAlphaBits32BitRle = "Tga/32bit_rle_no_alphabits.tga";
}
- public static class WebP
+ public static class Webp
{
// Reference image as png
public const string Peak = "Webp/peak.png";