-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
Thumbnail generation has wrong orientation #726
Comments
Hi @alxvallejo, that's meant to be a really minimal sample that uses the image manipulation tool built in to Cloud Functions for Firebase (ImageMagick). We have a sharp sample here: https://github.com/firebase/functions-samples/tree/master/image-sharp If you'd like to see a more productionized version that does account for rotation, you can take a look at the source for the |
The sharp sample is outdated. The max() method has been deprecated. What would really be helpful is to combine both simple approaches:
Right now, i'm unsure of how to do that given the example, since sharp seems to rely on streams with a promise that doesn't return the images for saving. |
Hi @alxvallejo Did you find a solution to this issue? Thank you |
@billymahmood Yes, actually made a PR, but haven't had time to format it -> #730 |
I'm not sure why the example isn't using sharp() since so many other example recommend using the library for image manipulation, but no image orientation fixes (rotate, crop) are being used in the sample. Can anyone explain why?
https://github.com/firebase/functions-samples/tree/master/generate-thumbnail
The text was updated successfully, but these errors were encountered: