composer require ingenerator/image-processing
Operations can be run in three different ways:
use Ingenerator\ImageProcessing\Processor\ImageOperations;
$processor = new ImageOperations;
['width', 'height'] = $processor->getImageSize('test/resources/porto_1024.jpg');
use Ingenerator\ImageProcessing\Processor\CLIImageProcessor;
$processor = new CLIImageProcessor;
['width', 'height'] = $processor->getImageSize('test/resources/porto_1024.jpg');
> php src/Processor/process.php getImageSize test/resources/porto_1024.jpg 0
[1024,786]