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

Corner artifacts in scans - define crop style (?) #5

Open
GregorKobsik opened this issue May 19, 2020 · 4 comments
Open

Corner artifacts in scans - define crop style (?) #5

GregorKobsik opened this issue May 19, 2020 · 4 comments

Comments

@GregorKobsik
Copy link

It is only possible to crop inner borders of the images.

a attribute, which defines the crop behaviour would allow to have also outer border crop.

e.g.
python print.py -border_crop 5 -crop_style INNER examples/decklist.txt decklist.pdf
crop only the inner border of the cards by 5px (default behaviour)

python print.py -border_crop 5 -crop_style ALL examples/decklist.txt decklist.pdf
crop all borders of the cards by 5px.

@DiddiZ
Copy link
Owner

DiddiZ commented May 19, 2020

What would be the use case for cropping the outer border?

Assuming you specify an inner crop, you are going to cut the cards to the sme size and thus cut the outer border anyway. The larger outer border allows for a cleaner cut without accidentally keeping a littel bit of white background.

@GregorKobsik
Copy link
Author

GregorKobsik commented May 20, 2020

A custom color background allows to define a seamleas background in the printing, although the corners of the images still introduce artifacts which are not desireable.

image

A full crop would allow to get rid of these artifacts and introduce an extended seamless border, which can be cut at every distance depending on the printer tolerances.

Sharp corners and quadratic cards are more desirable than round corners, as they introduce less postprocessing time needed for each produced card.

@GregorKobsik GregorKobsik changed the title Define crop style Corner artifacts in scans - define crop style (?) May 20, 2020
@GregorKobsik
Copy link
Author

another possibility would be to use an shrink operator on the whole image, to contract it by 1px or 2px from the outer edge, and hopefully removing those artifacts.

@AdamBajger
Copy link

AdamBajger commented May 13, 2024

I am working on a rewrite that introduces the requested features... along with some additional "intelligent" corner-filling logic.
But it will take a while probably. I have created a pull request already, but it is not ready yet.

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

No branches or pull requests

3 participants