Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added auto-crop support for PDF sources. #131

Merged
merged 1 commit into from
Jan 25, 2024
Merged

Added auto-crop support for PDF sources. #131

merged 1 commit into from
Jan 25, 2024

Conversation

lromor
Copy link
Collaborator

@lromor lromor commented Jan 23, 2024

No description provided.

src/pdf-image-source.cc Outdated Show resolved Hide resolved
@hzeller
Copy link
Owner

hzeller commented Jan 24, 2024

Nice!
Can you test with -W, -WU and -U as well ?
Another test-case would be to run with the quarter-pixelation as it has an unusual internal aspect ratio -pq

This will verify if the current order of translate and scale works well.

@hzeller
Copy link
Owner

hzeller commented Jan 24, 2024

Ah, and looks like the CI discovered that the version on the CI does not yet have the bounding-box call. We might need to if-def that feature out depending on when the bounding-box first appeared using the POPPLER_MAJOR_VERSION, POPPLER_MINOR_VERSION macros.

@hzeller
Copy link
Owner

hzeller commented Jan 24, 2024

It looks like that boundinng box call appeared in 0.88. So maybe an #if POPPLER_CHECK_VERSION(0, 88, 0) ?

src/pdf-image-source.cc Outdated Show resolved Hide resolved
@lromor lromor force-pushed the pdf-autocrop branch 3 times, most recently from fc9b77d to 6a1acff Compare January 24, 2024 19:44
@hzeller hzeller merged commit 1e86275 into main Jan 25, 2024
7 checks passed
@hzeller
Copy link
Owner

hzeller commented Jan 25, 2024

Cool, merged!

@hzeller hzeller deleted the pdf-autocrop branch January 25, 2024 00:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants