PHPackages                             rtablada/exif - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Image &amp; Media](/categories/media)
4. /
5. rtablada/exif

ActiveLibrary[Image &amp; Media](/categories/media)

rtablada/exif
=============

A package for dealing with exif image orientation

02331[2 PRs](https://github.com/rtablada/exif-rotator/pulls)PHP

Since Jul 1Pushed 12y ago1 watchersCompare

[ Source](https://github.com/rtablada/exif-rotator)[ Packagist](https://packagist.org/packages/rtablada/exif)[ RSS](/packages/rtablada-exif/feed)WikiDiscussions master Synced 2w ago

READMEChangelogDependenciesVersions (1)Used By (0)

EXIF Based Auto Rotation
------------------------

[](#exif-based-auto-rotation)

This is a simple class that allows you to auto-rotate your images based on EXIF data imbedded in JPG and TIFF images.

Installing
----------

[](#installing)

Add `"rtablada/exif": "dev-master"` to your `composer.json` file.

Use
---

[](#use)

Using this rotator takes a file path, SPLFileInfo instance, or Symfony\\Request\\UploadedFile along with an instance of Imagine (here we use GD). Then call `rotate` and you will be returned an auto-rotated image based on the EXIF data if any is present.

```
$imagine = new \Imagine\GD\Imagine;
$rotator = new \Rtablada\Exif\ExifRotator($pathToFile, $imagine);

$output = $resizer->rotate();
$output->save($outputPath);
```

Use with Stapler
----------------

[](#use-with-stapler)

This was originally built for use within a Laravel project using [Stapler](https://github.com/CodeSleeve/stapler). Using this rotator with Stapler is quite simple when defining your styles:

```
$this->hasAttachedFile('avatar', [
	'styles' => [
		'medium' => '300x300',
		'thumb' => function($file, $imagine) {
			$resizer = \Rtablada\Images\ResizeAndPad($file, $imagine);
			return $resizer->rotate();
		}
	]
]);
```

Shorthand
---------

[](#shorthand)

If you would like to quickly rotate an image you can use `makeAndRotate` which skips the step of having to instantiate the rotator:

```
\Rtablada\Images\ResizeAndPad::makeAndRotate($file, $imagine)->save($output);
```

###  Health Score

22

—

LowBetter than 21% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity12

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/ea9ccd400c74151601341e320935a31d1a9779c5eb49a8f364bc7a0ac75baa32?d=identicon)[rtablada](/maintainers/rtablada)

---

Top Contributors

[![rtablada](https://avatars.githubusercontent.com/u/2532004?v=4)](https://github.com/rtablada "rtablada (11 commits)")

### Embed Badge

![Health badge](/badges/rtablada-exif/health.svg)

```
[![Health](https://phpackages.com/badges/rtablada-exif/health.svg)](https://phpackages.com/packages/rtablada-exif)
```

###  Alternatives

[goat1000/svggraph

Generates SVG graphs

133890.0k3](/packages/goat1000-svggraph)[imagekit/imagekit

PHP library for Imagekit

46877.3k10](/packages/imagekit-imagekit)[gravatarphp/gravatar

Gravatar URL builder which is most commonly called as a Gravatar library

12644.1k2](/packages/gravatarphp-gravatar)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
