The following features are implemented when loading and saving WebP files:
Save lossy files by setting CodecsWebpSaveOptions.QualityFactor to a value in the range 1-24. Save lossless files by setting CodecsWebpSaveOptions.QualityFactor to 0.
Save a single page file using the RasterImageFormat.Webp format. Save animated files using the RasterImageFormat.Webpp format.
See Implementing Animation for more information on GIF and WebP animation files.
WebP files support Exif metadata. There is at most one Exif chunk per file, and even if a file has multiple frames as is the case in animated WebP files, all the frames have the same metadata.
Since WebP files have Exif metadata, they support the following features:
Read comment from a WebP file/stream using one the RasterCodecs.ReadComment methods.
Write comments to an existing WebP file/stream using RasterCodecs.WriteComment methods.
You can also write comments when you create a new file by populating the RasterImage.Comments collection before saving the file using one of the RasterCodecs.Save methods.
Delete comments from an existing file using RasterCodecs.DeleteComment methods.
In these methods, TIFF and Exif comments are supported.
Read tags from a WebP file/stream using RasterCodecs.ReadTag or RasterCodecs.ReadTags.
Write tags to an existing WebP file/stream using RasterCodecs.ReadTag.
Write tags when you create a new file by populating the RasterImage.Tags collection before saving the file using one of the RasterCodecs.Save methods.
RasterCodecs.ReadStamp and RasterCodecs.SaveStamp can be used to read/write stamps from/to an existing WebP file.
Save a stamp when you create a new file using CodecsWebpSaveOptions.SaveWithStamp, CodecsWebpSaveOptions.StampWidth, and CodecsWebpSaveOptions.StampHeight before saving the file using one of the RasterCodecs.Save methods.
WebP files support embedded ICC profiles. The ICC profile is applied automatically during load.
Check if a file has a profile using IccProfileExtended.ImageHasIccProfile.
Write a profile to an existing WebP file/stream using IccProfileExtended.WriteToImage.
Read a profile from an existing WebP file/stream using IccProfileExtended.ReadFromImage.
WebP files support XMP metadata. Read XMP metadata using RasterCodecs.ExtractXMPMetadata. Write XMP metadata to an existing file/stream using RasterCodecs.SaveXMPMetadata.
Help Collections
Raster .NET | C API | C++ Class Library | HTML5 JavaScript
Document .NET | C API | C++ Class Library | HTML5 JavaScript
Medical .NET | C API | C++ Class Library | HTML5 JavaScript
Medical Web Viewer .NET
Multimedia
Direct Show .NET | C API | Filters
Media Foundation .NET | C API | Transforms
Supported Platforms
.NET, Java, Android, and iOS/macOS Assemblies
Imaging, Medical, and Document
C API/C++ Class Libraries
Imaging, Medical, and Document
HTML5 JavaScript Libraries
Imaging, Medical, and Document