PHP Classes

Selective PHP Image Manipulation : Perform several types of image manipulation

Recommend this page to a friend!
  Info   Documentation   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not yet rated by the usersTotal: 76 All time: 10,177 This week: 57Up
Version License PHP version Categories
selective-image 1.0MIT/X Consortium ...5PHP 5, Graphics
Description 

Author

This class can perform several types of image manipulation.

It can load images from JPEG, PNG, GIF, and BMP files and perform several manipulations.

Currently, it can:

- Convert images into other formats

- Add a watermark image

- Resize the image

- Copy one image into another image

Picture of Chun-Sheng, Li
  Performance   Level  
Name: Chun-Sheng, Li <contact>
Classes: 39 packages by
Country: Taiwan Taiwan
Innovation award
Innovation award
Nominee: 17x

Winner: 1x

Documentation


Details

selective/image

Image manipulation library.

Latest Version on Packagist Software License Build Status Coverage Status Quality Score Total Downloads

Features

  • Converting images to JPEG, GIF, PNG, BMP (16-Bit and 24-Bit)
  • Changing the size and sharpness of images

Requirements

  • The ```GD``` extension

Installation

composer require selective/image

Usage

Create the image resource.

$image = new \Selective\Image\Image();

$imgSrc = $image->getImage('/path/to/odan.jpg');

Convert the image to the specific image type and get converted image data string.

$image->convertImage($imgSrc, '/path/to/odan.png', 0);
$imageData = $image->getImageData($imgSrc, 'png'));

Convert the image to the specific image type and get converted image data string.

$image->convertImage($imgSrc, '/path/to/odan.png', 0);
$imageResource = $image->getImage('/path/to/odan.png');

If you want more details and examples about usage, please read the documentation.


  Files folder image Files (18)  
File Role Description
Files folder imagedocs (6 files)
Files folder imagesrc (1 directory)
Files folder imagetests (3 files)
Accessible without login Plain text file .cs.php Example Example script
Accessible without login Plain text file .scrutinizer.yml Data Auxiliary data
Accessible without login Plain text file .styleci.yml Data Auxiliary data
Accessible without login Plain text file .travis.yml Data Auxiliary data
Accessible without login Plain text file composer.json Data Auxiliary data
Accessible without login Plain text file LICENSE Lic. License text
Accessible without login Plain text file phpunit.xml Data Auxiliary data
Accessible without login Plain text file README.md Doc. Documentation

  Files folder image Files (18)  /  docs  
File Role Description
  Accessible without login Plain text file add_watermark.md Data Auxiliary data
  Accessible without login Plain text file convert_image.md Data Auxiliary data
  Accessible without login Plain text file create_image.md Data Auxiliary data
  Accessible without login Plain text file output_image.md Data Auxiliary data
  Accessible without login Plain text file README.md Doc. Documentation
  Accessible without login Plain text file resize_image.md Data Auxiliary data

  Files folder image Files (18)  /  src  
File Role Description
Files folder imageImage (1 file)

  Files folder image Files (18)  /  src  /  Image  
File Role Description
  Plain text file Image.php Class Class source

  Files folder image Files (18)  /  tests  
File Role Description
  Accessible without login Image file background.jpeg Icon Icon image
  Accessible without login Plain text file ImageTest.php Test Test class source
  Accessible without login Image file odan.jpg Icon Icon image

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 100%
Total:76
This week:0
All time:10,177
This week:57Up