You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, first off I wanted to thank you so much for the implementation- playing around with this has been my first real stepping stone into Rust, and you've made it pretty easy!
During my tinkering, I've been trying to use some local images I had laying around, and noticed that some of them would silently fail. Namely, the ones that weren't already square. The images crate provides a resize_exact method for DynamicImage that works for resizing these in a local vendored copy of the code- do you think it would be worth adding an option to use it? If so, I could probably contribute a PR. If not, I could also contribute a PR updating the documentation to specify that only 1:1 AR images should be used. Either way, thank you!
The text was updated successfully, but these errors were encountered:
hey thanks for the issue, i'm glad it's (mostly) working for you!
changing the default behaviour to scale non square images (rather than failing) seems like a good general improvement, though i am not sure whether this would better be accomplished via an resize_exact or a scale-to-fit (ie. does it stretch without maintaining the aspect ratio, or, fit the largest dimension while maintaining the ratio)?
perhaps we could have an enum representing scaling modes in the ImageOptions object similar to what was partially implemented in #9 for centring text.
Hello, first off I wanted to thank you so much for the implementation- playing around with this has been my first real stepping stone into Rust, and you've made it pretty easy!
During my tinkering, I've been trying to use some local images I had laying around, and noticed that some of them would silently fail. Namely, the ones that weren't already square. The
images
crate provides aresize_exact
method for DynamicImage that works for resizing these in a local vendored copy of the code- do you think it would be worth adding an option to use it? If so, I could probably contribute a PR. If not, I could also contribute a PR updating the documentation to specify that only 1:1 AR images should be used. Either way, thank you!The text was updated successfully, but these errors were encountered: