Skip to content


Subversion checkout URL

You can clone with
Download ZIP


Add support for 'rotate' option #141

cmer opened this Issue · 7 comments

5 participants


Possibly only supporting 90, 180 and 270 degrees.


It's possible to flip the image pixels, which is not exactly a rotation, but could solve your case:

-Ex-F means resize the image to be ExF of width per height size. The minus signs mean flip horizontally and vertically;

So if you do it will flip image pixels on the x and y axis, which is what rotate 180 does.

But yeah, besides that, 90 and 270 degrees are not supported right now.


I really meant a good ol' rotation. The reason for this is that we let our users upload pictures and sometimes, they're sideways or upside down. We have a button to let them rotate them on the screen (javascript + css) and when they submit the form, we store the rotation. We need a way to be able to display their pictures properly rotated later.

Right now we use Carrierwave but I'd like to move towards generating images on the fly and was considering Thumbor.


I like the 90 degree increment option. When you move into any degree then you have to take into account whether you expand the bounding box of the image or clip.


The problem with this is that we'd have to take into account that rotating has to come before anything is done with the image.
Thumbor has a "contract" with the users that if you ask it for a 300x200 image, you'll get a 300x200 image.
If rotating is done after cropping and resizing, we'd return a 200x300 image, which is not what the user expected.

Other than that this is really simple to implement. Anyone want to tackle it? The main issue here is actually implementing the sintax in the libs (libthumbor, rubythumbor, phumbor, polexor, etc).


I'd also love to see a rotate option (90 degree increments). I created a bounty for this feature over on Bountysource. Hopefully some others who also want this feature will add to the bounty!


This can be easily implemented as a filter: rotate(90). Then no changes to the libs need to be done.

@heynemann heynemann closed this in e8a377a

Just to let everyone know, this is live in Release 4.3.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.