[wp-trac] [WordPress Trac] #13461: Preserve GIF transparency/alpha during thumbnail creation

WordPress Trac noreply at wordpress.org
Thu Oct 25 22:06:05 UTC 2012


#13461: Preserve GIF transparency/alpha during thumbnail creation
-------------------------------------------------+-------------------------
 Reporter:  javitxu123                           |       Owner:
     Type:  defect (bug)                         |      Status:  new
 Priority:  normal                               |   Milestone:  Future
Component:  Media                                |  Release
 Severity:  normal                               |     Version:  2.9.2
 Keywords:  needs-testing needs-patch 2nd-       |  Resolution:
  opinion                                        |
-------------------------------------------------+-------------------------

Comment (by bpetty):

 Just some additional notes based on my own findings...

 While I was able to modify wp_imagecreatetruecolor() in a way that gets
 this working well with resizing and cropping, this isn't enough.

 - The same approach can not be used with the GD imagerotate() method which
 throws away transparency info in the image in it's own way too, so it
 needs it's own patch.
 - Also, image flipping is in it's own boat too where the same tricks
 applied to get resize/crop to work with GIF transparency actually
 completely break image flipping to where the whole image is lost.

 I'll attach my semi-working patch (resize/crop working, but rotate/flip
 broken) later here for anyone that wants to take over.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/13461#comment:17>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list