Browse Source

Change samples per pixel to ushort

pull/2298/head
Brian Popow 4 years ago
parent
commit
4aec7aae56
  1. 4
      src/ImageSharp/Formats/Tiff/TiffEncoderEntriesCollector.cs

4
src/ImageSharp/Formats/Tiff/TiffEncoderEntriesCollector.cs

@ -278,7 +278,7 @@ internal class TiffEncoderEntriesCollector
Value = (ushort)TiffPlanarConfiguration.Chunky Value = (ushort)TiffPlanarConfiguration.Chunky
}; };
ExifLong samplesPerPixel = new(ExifTagValue.SamplesPerPixel) ExifShort samplesPerPixel = new(ExifTagValue.SamplesPerPixel)
{ {
Value = GetSamplesPerPixel(encoder) Value = GetSamplesPerPixel(encoder)
}; };
@ -317,7 +317,7 @@ internal class TiffEncoderEntriesCollector
} }
} }
private static uint GetSamplesPerPixel(TiffEncoderCore encoder) private static ushort GetSamplesPerPixel(TiffEncoderCore encoder)
=> encoder.PhotometricInterpretation switch => encoder.PhotometricInterpretation switch
{ {
TiffPhotometricInterpretation.PaletteColor or TiffPhotometricInterpretation.PaletteColor or

Loading…
Cancel
Save