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

Does it do upscaling ? and what about center fit cropping ? #130

Open
fahadzafar opened this issue Mar 12, 2018 · 3 comments
Open

Does it do upscaling ? and what about center fit cropping ? #130

fahadzafar opened this issue Mar 12, 2018 · 3 comments

Comments

@fahadzafar
Copy link

fahadzafar commented Mar 12, 2018

i want to upscale images, then fit them to certain dimensions, I'm okay with cropping loss at the edges, but i want to maintain the aspect ratio and center the image. Asking this because i read in the doc, that cropping happens starting top left.

currently im doing this to a test image of 1200x1800
convert test.png -resize 1300x1300^ -gravity center -extent 1300x1300 -quality 100 converted_not.jpg

i just wana do it in code. Some clarification would be most appreciated.

thanks

@herath
Copy link

herath commented May 15, 2018

+1

1 similar comment
@rafacustodio
Copy link

+1

@manvydasu
Copy link

@fahadzafar Did you manage to find way to scale and center fit with colored padding?

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

4 participants