承接 mvccore/ext-tool-image 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

mvccore/ext-tool-image

Composer 安装命令:

composer require mvccore/ext-tool-image

包简介

MvcCore - Extension - Tool - Image - object oriented image processing tool supporting many popular web images operations.

README 文档

README

Latest Stable Version License PHP Version

Installation

composer require mvccore/ext-tool-image

Features

Extension helps to process many popular web images operations:

Image	Image::AddOverlay($overlayImgFullPath, $x, $y, $alpha, $composite); // Adding overlay image is not implemented for Gd adapter
Image	Image::ApplyMask($maskImgFullPath);
Image	Image::Contain($width, $height);
Image	Image::Cover($width, $height, $orientation);
Image	Image::CreateEmptyImageResource($width, $height, $hexBgColor = 'transparent');
Image	Image::Crop($x, $y, $width, $height);
Image	Image::CropPercent($xPercentage, $yPercentage, $widthPercentage, $heightPercentage);
Image	Image::Frame($width, $height);
int	Image::GetHeight();
int	Image::GetWidth();
Image	Image::Grayscale();
array	Image::HexColor2RgbArrayColor($hexColor);
bool	Image::IsVectorGraphic();
Image	Image::Load($imgFullPath);
Image	Image::Resize($width, $height);
Image	Image::ResizeByHeight($height);
Image	Image::ResizeByPixelsCount($count);
Image	Image::ResizeByWidth($width);
Image	Image::Rotate($angle);
Image	Image::RoundCorners($x, $y);
Image	Image::Sepia($threshold = 80);
Image	Image::SetBackgroundColor($hexColor);
Image	Image::SetBackgroundImage($bgImgFullPath);
Image	Image::Save($imgFullPath, $format, $quality);
Image	Image::UnsharpMask($amount, $radius, $threshold);

Usage

<?php

include_once('vendor/autoload.php');

use \MvcCore\Ext\Tools;

// resize `source.jpg` to `thumb.jpg`:
$image = Tools\Image::CreateInstance()
    ->Load(__DIR__ . "/source.jpg")
    ->ResizeByHeight(150)
    ->UnsharpMask(300, 0.7, 50)
    ->Save(
        __DIR__ . "/thumb.jpg",
        Tools\Images\IFormat::JPG,
        100
    );

// display original and resized image:
echo '<html><body>',
     '<img src="source.jpg" />',
     '<br />',
     '<img src="thumb.jpg" />',
     '</body></html>';

Imagick Windows binaries for dummies:

统计信息

  • 总下载量: 229
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 1
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: BSD-3-Clause
  • 更新时间: 2017-11-16

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固