|
|
|
@ -10,7 +10,6 @@ using SixLabors.ImageSharp.Metadata.Profiles.Icc; |
|
|
|
using SixLabors.ImageSharp.PixelFormats; |
|
|
|
using SixLabors.ImageSharp.Processing; |
|
|
|
using SixLabors.ImageSharp.Tests.TestUtilities; |
|
|
|
using static SixLabors.ImageSharp.Metadata.Profiles.Exif.EncodedString; |
|
|
|
|
|
|
|
// ReSharper disable InconsistentNaming
|
|
|
|
namespace SixLabors.ImageSharp.Tests.Formats.Jpg; |
|
|
|
@ -496,17 +495,15 @@ public partial class JpegDecoderTests |
|
|
|
Assert.Equal("Carers; seniors; caregiver; senior care; retirement home; hands; old; elderly; elderly caregiver; elder care; elderly care; geriatric care; nursing home; age; old age care; outpatient; needy; health care; home nurse; home care; sick; retirement; medical; mobile; the elderly; nursing department; nursing treatment; nursing; care services; nursing services; nursing care; nursing allowance; nursing homes; home nursing; care category; nursing class; care; nursing shortage; nursing patient care staff\0", exifProfile.GetValue(ExifTag.XPKeywords).Value); |
|
|
|
|
|
|
|
Assert.Equal( |
|
|
|
new EncodedString(CharacterCode.ASCII, "StockSubmitter|Miscellaneous||Miscellaneous$|00|0000330000000110000000000000000|22$@NA_1005010.460@145$$@Miscellaneous.Miscellaneous$$@$@26$$@$@$@$@205$@$@$@$@$@$@$@$@$@43$@$@$@$$@Miscellaneous.Miscellaneous$$@90$$@22$@$@$@$@$@$@$|||"), |
|
|
|
new EncodedString(EncodedString.CharacterCode.ASCII, "StockSubmitter|Miscellaneous||Miscellaneous$|00|0000330000000110000000000000000|22$@NA_1005010.460@145$$@Miscellaneous.Miscellaneous$$@$@26$$@$@$@$@205$@$@$@$@$@$@$@$@$@43$@$@$@$$@Miscellaneous.Miscellaneous$$@90$$@22$@$@$@$@$@$@$|||"), |
|
|
|
exifProfile.GetValue(ExifTag.UserComment).Value); |
|
|
|
|
|
|
|
// the profile contains 4 duplicated UserComment
|
|
|
|
Assert.Equal(1, exifProfile.Values.Count(t => t.Tag == ExifTag.UserComment)); |
|
|
|
|
|
|
|
image.Mutate(x => x.Crop(new(0, 0, 100, 100))); |
|
|
|
|
|
|
|
image.Save(ms, new JpegEncoder()); |
|
|
|
|
|
|
|
foreach (IExifValue val in image.Metadata.ExifProfile.Values) |
|
|
|
{ |
|
|
|
this.Output.WriteLine($"{val.Tag}={val.GetValue()}"); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
private static void VerifyEncodedStrings(ExifProfile exif) |
|
|
|
|