简体   繁体   中英

Paperclip - Wrong image orientation

I'm using Paperclip 4.1.1 for images uploading. I store three sizes, original, medium and thumbnail. When I try to show the original images, some of them appear rotated to the left, and it happens randomly, because some others are displayed correctly. This does not happen with medium and thumbnail sizes. The funny fact is that if I open any original image url on a browser, it always displays correctly. Any thoughts?

EDIT:

According to this comment in the Paperclip Railscast , this behavior doesn't occur on processed images. As a workaround, I added a new Paperclip style big enough to meet my requirements.

Check this How to set Paperclip to process original image? this will help. Adding original: {convert_options: '-strip'} in styles help

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM