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

Reserve enough margin to be cropped #81

Merged

Conversation

thawk
Copy link
Contributor

@thawk thawk commented Jan 18, 2020

Make sure the sanitised image has enough margin (half of height for top/bottom) to be cropped.

Copy link
Owner

@aspiers aspiers left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can't remember exactly how this is supposed to work but this sounds reasonable so taking it on trust it works 😁

@aspiers aspiers merged commit cd3b546 into aspiers:dependabot/pip/pillow-6.2.0 Jan 18, 2020
@thawk
Copy link
Contributor Author

thawk commented Jan 18, 2020

I can't remember exactly how this is supposed to work but this sounds reasonable so taking it on trust it works 😁

I have a score, which is only more than 100 pixels height, so its center line is at only 2xx. Because the video height is 720, it requires that the center line is at least 360 to have a non-negative top coordinate. So I add more margin to make sure a center line is not less than halft height of the final video.

@aspiers
Copy link
Owner

aspiers commented Jan 18, 2020

Thanks for the explanation 👍

@thawk thawk deleted the reserve_enought_margin branch January 31, 2020 11:57
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.

2 participants