[wp-trac] [WordPress Trac] #14459: Rotate Full Size Images on Upload

WordPress Trac noreply at wordpress.org
Thu Aug 15 02:03:35 UTC 2019


#14459: Rotate Full Size Images on Upload
-------------------------------------------------+-------------------------
 Reporter:  mrroundhill                          |       Owner:
                                                 |  mikeschroder
     Type:  enhancement                          |      Status:  reviewing
 Priority:  normal                               |   Milestone:  Future
                                                 |  Release
Component:  Media                                |     Version:  3.0
 Severity:  normal                               |  Resolution:
 Keywords:  has-patch needs-testing needs-unit-  |     Focuses:
  tests                                          |
-------------------------------------------------+-------------------------

Comment (by azaozz):

 > as mentioned above, there is a slight "quirk" when a JPEG is uploaded
 using the block editor (as opposed to in the Media Library or classic
 editor "Add Media"). If the image has an EXIF orientation tag that
 indicates the image is rotated, the image momentarily displays in the
 rotated orientation in the block editor but then quickly corrects itself.

 That happens as when uploading from the Image block, there is a "preview"
 of the image (shown from js) while the actual image is being uploaded.
 That preview doesn't follow the EXIF orientation (or rather the browser
 doesn't). After the image has finished uploading, and sub-sizes were
 created, the preview is replaced with the "proper" source.

 Thinking this can be fixed there, but not very straightforward. Would need
 to read EXIF from js, then rotate the image before displaying the preview.
 This may need quite a bit of memory (in the browser) but will probably be
 fine.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/14459#comment:78>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list