auto-orientation for images in strip command as exif orientation does not work in browsers with webp
This commit is contained in:
@@ -3,6 +3,7 @@ using SixLabors.ImageSharp.Web;
|
||||
using SixLabors.ImageSharp.Web.Commands;
|
||||
using SixLabors.ImageSharp.Web.Processors;
|
||||
using System.Globalization;
|
||||
using SixLabors.ImageSharp.Processing;
|
||||
|
||||
namespace zero.Media.ImageSharp.Processors;
|
||||
|
||||
@@ -35,6 +36,8 @@ public class StripMetadataWebProcessor : IImageWebProcessor
|
||||
|
||||
if (strip)
|
||||
{
|
||||
image.Image.Mutate(x => x.AutoOrient());
|
||||
|
||||
image.Image.Metadata.ExifProfile = null;
|
||||
image.Image.Metadata.XmpProfile = null;
|
||||
image.Image.Metadata.IptcProfile = null;
|
||||
|
||||
Reference in New Issue
Block a user