sungaila / PDFtoImage

A .NET library to render PDF files into images.
https://www.sungaila.de/PDFtoImage/
MIT License
176 stars 19 forks source link

Replacing System.Drawing.Common (GDI+) with SkiaSharp #5

Closed sungaila closed 2 years ago

sungaila commented 2 years ago

Support for System.Drawing.Common (GDI+) on other platforms than Windows will stop with .NET 6.0 and newer: System.Drawing.Common only supported on Windows

This project used GDI+ for encoding the bitmap provided by PDFium when rendering. PDFium just returns a pointer to the memory it stored its rendered PDF bitmap.

GDI+ supports BMP, GIF, JPEG, PNG and TIFF as output image formats.

I decided for SkiaSharp as a cross-platform replacement. However, it has two drawbacks found so far:

On the positive side: