hashwallet / image
支持Laravel集成的图像处理和操作库
dev-main
2024-09-05 02:29 UTC
Requires
- php: >=5.4.0
- ext-fileinfo: *
- guzzlehttp/psr7: ~1.1 || ^2.0
Requires (Dev)
- mockery/mockery: ~0.9.2
- phpunit/phpunit: ^4.8 || ^5.7 || ^7.5.15
Suggests
- ext-gd: to use GD library based image processing.
- ext-imagick: to use Imagick based image processing.
- intervention/imagecache: Caching extension for the Intervention Image library
This package is not auto-updated.
Last update: 2024-09-20 01:06:34 UTC
README
Intervention Image 是一个 PHP 图像处理和操作 库,提供了一种更简单、更直观的方式来创建、编辑和组合图像。该包包括 ServiceProviders 和 Facades 以便于 Laravel 集成。
要求
- PHP >=5.4
- Fileinfo 扩展
支持的图像库
- GD 库 (>=2.0)
- Imagick PHP 扩展 (>=6.5.7)
入门
代码示例
// open an image file $img = Image::make('public/foo.jpg'); // resize image instance $img->resize(320, 240); // insert a watermark $img->insert('public/watermark.png'); // save image in desired format $img->save('public/bar.jpg');
请参阅官方文档以了解更多关于Intervention Image的信息。
贡献
欢迎对Intervention Image库的贡献。在提交您的pull request之前,请注意以下指南。
- 遵循PSR-2编码标准。
- 为新的函数和添加的功能编写测试
- API调用应与GD和Imagick驱动程序一致
许可
Intervention Image 在MIT 许可下授权。
版权 2017 Oliver Vogel