Download the PHP package takuya/php-imagick-cmd-wrapper without Composer
On this page you can find all versions of the php package takuya/php-imagick-cmd-wrapper. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download takuya/php-imagick-cmd-wrapper
More information about takuya/php-imagick-cmd-wrapper
Files in takuya/php-imagick-cmd-wrapper
Package php-imagick-cmd-wrapper
Short Description image magick command line call from php
License GPL-3.0-or-later
Informations about the package php-imagick-cmd-wrapper
php-imagick-cmd-wrapper
Image magick shell command wrapper for php
requirements
Why using magick shell command from php?
Occasionally, a php-imagick (ext-imagick) is not available.
Some mod-php server are not supporting ext-imagck. but convert command is easy to install.
Imagick class ( in ext-imagick) is not documented in precisely.
Think, Can you tell how to use 'png:compression-filter' in ext-imagick ?. Perhaps you can't.
But, there are very many 'convert' samples in web. and we are trying to system('convert a.jpg b.png')
calling with escaping shell arguments. What's a irritated.
So, we need convert
command wrapper.
Installing from GitHub
Usage Sample
Important Notice! Call Method Ordering.
Before Use, You should know that OPTIONS Ordering is VERY IMPORTANT.
The convert
command is Very NAIVE for option order.
We must care about Arguments Ordering.
Sample1 ( vain , not working. )
This result in identify a.jpg -format '[%w,%h]'
, but no work.
Sample2 ( works fine. )
This result in identify -format '[%w,%h]' a.jpg
, it will work fine.
More Sample Usage
Convert JPEG to PNG.
Using STDOUT - converting jpeg to png
Using STDIN - converting jpeg to png
Structure of return value
command result is array of 3 entries
Resize(sampling Algorithm) and UnSharp and Normalization
IDE Auto Completion.
Options(methods) are auto generated from Help doc from 'convert -h'.
So, in Some IDE, Auto completions will not work fine.
If it happens then add a path src/generated/
to your Project search PATH.
Developing notice.
This project uses auto generated php code, parsing converet -h
.
If you want to re-generate class, execute these command in CLI.
I used these environment. wsl1 debian.
imagemagick from debian(wsl)