mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2024-11-21 21:55:38 +00:00
Improved the texture size accuracy when rendering pages using es-pdf-convert
This commit is contained in:
parent
1dca0673c5
commit
b847b15e07
|
@ -209,9 +209,8 @@ int main(int argc, char* argv[])
|
|||
const double pageHeight {pageRect.height()};
|
||||
const double sizeFactor {static_cast<double>(rotate ? height : width) / pageHeight};
|
||||
|
||||
poppler::image image {pageRenderer.render_page(
|
||||
page, static_cast<int>(std::round(72.0 * sizeFactor)),
|
||||
static_cast<int>(std::round(72.0 * sizeFactor)), 0, 0, width, height)};
|
||||
poppler::image image {
|
||||
pageRenderer.render_page(page, 72.0 * sizeFactor, 72.0 * sizeFactor, 0, 0, width, height)};
|
||||
|
||||
if (!image.is_valid()) {
|
||||
std::cerr << "Rendered image is invalid" << std::endl;
|
||||
|
|
Loading…
Reference in a new issue