Make WordPress Core

Changeset 29291


Ignore:
Timestamp:
07/24/2014 10:13:19 PM (10 years ago)
Author:
wonderboymusic
Message:

Add exif orientation to data extracted in wp_read_image_metadata().

Props shanebp.
Fixes 28916.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/image.php

    r29206 r29291  
    274274        'shutter_speed' => 0,
    275275        'title' => '',
     276        'orientation' => 0,
    276277    );
    277278
     
    389390        if ( ! empty( $exif['ExposureTime'] ) ) {
    390391            $meta['shutter_speed'] = (string) wp_exif_frac2dec( $exif['ExposureTime'] );
     392        }
     393        if ( ! empty( $exif['Orientation'] ) ) {
     394            $meta['orientation'] = $exif['Orientation'];
    391395        }
    392396    }
Note: See TracChangeset for help on using the changeset viewer.