zaachi / php-instagram-effects
PHP类,用于实现类似于Instagram的照片效果
dev-master
2016-02-08 14:40 UTC
Requires
- ext-gd: *
This package is not auto-updated.
Last update: 2024-09-18 07:56:26 UTC
README
PHP类,用于实现类似于Instagram的照片效果
使用方法
use Zaachi\Image\Filter; require 'vendor/autoload.php'; $image = imagecreatefromjpeg("/path/to/image.jpg"); $filter = (new Filter($image))->aqua(); header('Content-type: image/jpeg'); imagejpeg($filter->getImage());
使用示例位于examples
目录中。要生成示例图像,以下bash片段可能很有帮助
for f in *.php; do php $f > ${f%.php}.png; done