if (usesJbig2)
{
// Direct GetPixmap() on some FreePic2Pdf JBIG2 scans can yield black images.
// ConvertToPdf rewraps content into a new PDF that MuPDF can render reliably.
byte[] pdfBytes = doc.Convert2Pdf();
using var conv = new Document("pdf", pdfBytes);
using var convPage = conv[0];
pix = convPage.GetPixmap();
}
look at this