Enum TiffSampleFormat
How a page's samples are numbers, from the SampleFormat tag.
[SuppressMessage("Naming", "CA1720:Identifier contains type name", Justification = "These are the TIFF specification's names.")]
public enum TiffSampleFormat
Fields
Float = 3IEEE floating point (3).
SignedInteger = 2Two's complement integers (2), read offset to unsigned so 0 becomes the middle value.
UnsignedInteger = 1Unsigned integers (1).
Examples
using Raster page = Raster.Load("scan.tif");
TiffDetails tiff = (TiffDetails)page.Metadata.FormatDetails!;
Console.WriteLine($"page {tiff.PageIndex}: {tiff.Photometric}, {tiff.BitsPerSample}-bit, {tiff.Compression}, {tiff.ByteOrder}, {tiff.Layout}");
Console.WriteLine(tiff.TileWidth is int tile ? $"tiles of {tile}" : $"{tiff.RowsPerStrip} rows a strip");
// Tags Egami does not map are kept as they were read.
foreach (TiffTag tag in tiff.OtherTags)
{
Console.WriteLine($"tag {tag.Id}: {tag.Count} × {tag.Type}");
}