Ticket #30596: class-wp-image-editor-gd.php.patch
| File class-wp-image-editor-gd.php.patch, 726 bytes (added by , 11 years ago) |
|---|
-
class-wp-image-editor-gd.php
306 306 */ 307 307 public function rotate( $angle ) { 308 308 if ( function_exists('imagerotate') ) { 309 $rotated = imagerotate( $this->image, $angle, 0 ); 309 $transparency = imagecolorallocatealpha( $this->image, 255, 255, 255, 127 ); 310 $rotated = imagerotate( $this->image, $angle, $transparency ); 310 311 311 312 if ( is_resource( $rotated ) ) { 313 imagealphablending($rotated, true); 314 imagesavealpha($rotated, true); 312 315 imagedestroy( $this->image ); 313 316 $this->image = $rotated; 314 317 $this->update_size();