Skip to content

Update README.md to clarify specifying orientation from Exif data #82

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Oct 8, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 9 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -194,9 +194,11 @@ Requires `canvas: true`.
* **crop**: Crops the image to the maxWidth/maxHeight constraints if set to
`true`.
Enabling the `crop` option also enables the `canvas` option.
* **orientation**: Allows to transform the canvas coordinates according to the
EXIF orientation specification.
Setting the `orientation` also enables the `canvas` option.
* **orientation**: Transform the canvas according to the
specified Exif orientation (number in range 1 to 8). See
[loadImage.parseMetaData](https://github.com/blueimp/JavaScript-Load-Image#meta-data-parsing)
for parsing EXIF data. Setting the `orientation` also enables the `canvas`
option.
* **canvas**: Returns the image as
[canvas](https://developer.mozilla.org/en/HTML/Canvas) element if set to `true`.
* **crossOrigin**: Sets the crossOrigin property on the img element for loading
Expand Down Expand Up @@ -266,9 +268,9 @@ Blob objects of resized images can be created via
[canvas.toBlob()](https://github.com/blueimp/JavaScript-Canvas-to-Blob).

### Exif parser
If you include the Load Image Exif Parser extension, the **parseMetaData**
callback **data** contains the additional property **exif** if Exif data could
be found in the given image.
If you include the Load Image Exif Parser extension, the argument passed to the
callback for **parseMetaData** will contain the additional property **exif** if
Exif data could be found in the given image.
The **exif** object stores the parsed Exif tags:

```js
Expand Down Expand Up @@ -313,3 +315,4 @@ The JavaScript Load Image script is released under the
Achim Stöhr.
* Exif tags mapping based on Jacob Seidelin's
[exif-js](https://github.com/jseidelin/exif-js).