PHPackages                             root4root/imgresize - 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. root4root/imgresize

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

root4root/imgresize
===================

Yet another images resize library

v1.0.1(5y ago)218MITPHPPHP &gt;=5.4.0

Since Feb 15Pushed 5y ago1 watchersCompare

[ Source](https://github.com/root4root/imgresize)[ Packagist](https://packagist.org/packages/root4root/imgresize)[ RSS](/packages/root4root-imgresize/feed)WikiDiscussions master Synced 3d ago

READMEChangelog (2)DependenciesVersions (3)Used By (0)

ImgResize
=========

[](#imgresize)

[![License: MIT](https://camo.githubusercontent.com/fdf2982b9f5d7489dcf44570e714e3a15fce6253e0cc6b5aa61a075aac2ff71b/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d4d49542d79656c6c6f772e737667)](https://opensource.org/licenses/MIT)

Yet another library based on gd to resize images with method chaining.

### Examle

[](#examle)

```
require_once ('vendor/autoload.php');

use Root4root\ImgResize\ImgResize;

$image = new ImgResize('pathToImage.jpg');

$image->resampleToHeight(500)
    ->sharpen()
    ->save('pathToSave.gif');

$watermark = new ImgResize('pathToWatermark.png');

$image->addImage(new ImgResize('anotherImage.png'))
    ->joinVertical()
    ->watermark($watermark)
    ->save('pathToSave.jpg');

$image->watermark($watermark)->save('pathToSave2.jpg');
```

### Notes

[](#notes)

Every time you modify image, ImgResize returns new instanse of self as a result. So you could assign instance to a variable at any moment, which will stay immutable. Be careful with saving instances due to the memory limit, though.

```
$imageWithWatermark = (new ImgResize('pathToImage.jpg'))->watermark(new ImgResize('pathToWater.png'));
$imageWithWatermark->resampleToRectangle(500,500)->save('path.jpg'); //Fits image to rectangle by height or width - which is bigger.
$imageWithWatermark->resampleToWidth(1000)->sharpen()->save('path.png'); //Still one resample - best quality
```

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity9

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity56

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.

###  Release Activity

Cadence

Every ~586 days

Total

2

Last Release

2059d ago

### Community

Maintainers

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

---

Top Contributors

[![root4root](https://avatars.githubusercontent.com/u/11481734?v=4)](https://github.com/root4root "root4root (2 commits)")

---

Tags

imagesmethod-chainingphpresizeresizeimages

### Embed Badge

![Health badge](/badges/root4root-imgresize/health.svg)

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

###  Alternatives

[intervention/image

PHP Image Processing

14.3k194.3M2.2k](/packages/intervention-image)[gumlet/php-image-resize

PHP class to re-size and scale images

1.2k5.7M54](/packages/gumlet-php-image-resize)[rosell-dk/webp-convert

Convert JPEG &amp; PNG to WebP with PHP

6038.1M54](/packages/rosell-dk-webp-convert)[jbzoo/image

A PHP class that simplifies working with images

171126.9k3](/packages/jbzoo-image)[intervention/image-laravel

Laravel Integration of Intervention Image

1496.5M102](/packages/intervention-image-laravel)[ayvazyan10/nova-imagic

Imagic is a Laravel Nova field package that allows for image manipulation capabilities, such as cropping, resizing, quality adjustment, and WebP conversion. It utilizes the powerful Intervention Image class for image manipulation.

144.3k1](/packages/ayvazyan10-nova-imagic)

PHPackages © 2026

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