Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

ImageMagick rotates CW while imagerotate() rotates CCW

  • Loading branch information...
commit ba66e17d1d8ce6400db7a63d16a004c1a5898820 1 parent 0c67649
fermionic authored August 04, 2012

Showing 1 changed file with 1 addition and 1 deletion. Show diff stats Hide diff stats

  1. 2  include/Photo.php
2  include/Photo.php
@@ -247,7 +247,7 @@ public function rotate($degrees) {
247 247
         if($this->is_imagick()) {
248 248
             $this->image->setFirstIterator();
249 249
             do {
250  
-                $this->image->rotateImage(new ImagickPixel(), $degrees);
  250
+                $this->image->rotateImage(new ImagickPixel(), -$degrees); // ImageMagick rotates in the opposite direction of imagerotate()
251 251
             } while ($this->image->nextImage());
252 252
             return;
253 253
         }

0 notes on commit ba66e17

Please sign in to comment.
Something went wrong with that request. Please try again.