fix negated 1bpp TIFs with Photometric.MINISBLACK
TIF images with Photometric.MINISBLACK are being extracted with their colors negated (white is black and black is white).
I think this is because TIFs with the Photometric tag set to MINISBLACK have their image data negated and System.Drawing.Bitmap doesn't appear to allow setting this, so it displays the data as-is, which is negated.
The only way I've found to fix this is to negate the image data in ImageFromCCITTFaxDecode if CCITTFaxDecodeParameters.BlackIs1 is false.
This should fix the issues complaining about this problem - #6 and #8
Hi, I've got a modern fork github.com/Open-Inventions/PDFSharp.Extensions with ImageSharp and .NET 6 if you are interested.
@husaft any chance of getting your fork as a NuGet package?
@husaft any chance of getting your fork as a NuGet package?
Yes, it's now in https://www.nuget.org/packages/PdfSharpCore.Extensions !