Open michaelpastushkov opened 6 days ago
@michaelpastushkov. I've just added width and height options to PDFiumPage.render function in v1.0.3 version
Thanks a lot! One small addition that might save a lot of debugging time for many - round to the lower integer number inside your code. Or else we have to do it in ours (sizes are often calculated and may have decimals, in which case the render fails).
const bitmap = await pdf_page.render({
width: Math.floor(dst_width),
height: Math.floor(dst_height),
render: 'bitmap'
});
Can you please make scaling to accept width and height number, instead of just one for both. This would be a great help for many situations. BTW muPDF does that. Great simple wrapper otherwise!! Tx.