PHP Image Manipulation Class

PHP Image Manipulation Class can be used to perform several types of image manipulation operations. It can rescale images to fit in a given width or height keeping (or not) the original aspect ratio, flip images horizontally or vertically, and rotate images by a given angle while filling the empty spaces with a given color. All operations preserve transparency. The class does all the error checking for the source and target files. The class supports loading and saving images in the GIF, JPEG, and PNG formats.

Tags Software Development Libraries php classes
Operating Systems OS Independent
Implementation PHP

Tweet this project Short link

Rss Recent releases

  • Rrelease-mid
  •  27 Aug 2007 07:24
  • Rrelease-after

Changes: A bug was fixed where the resize() method would produce unexpected results when the actual width of the image was smaller than the value of the resizeToWidth property and resizeIfSmaller property was set to FALSE. In this case, if the height of the image was to be adjusted upwards, the width of the image was increased indefinitely, not taking into account the value of resizeToWidth.

  • Rrelease-mid
  •  13 Oct 2006 02:05
  • Rrelease-after

Changes: The crop() method was added. The preserveSourceFileTime property was added, which instructs the scripts to preserve the date and time of the source files and pass them on to the target files. The flip methods now use the imagecopyresampled function instead of using imagecopy. The script no longer crashes when a valid path which is not a file is specified as a source file. Error handling for the create_image_from_source_file() private method was fixed, so the script can no longer be easily crashed by specifying bogus source files.

  • Rrelease-mid
  •  13 Sep 2006 04:45
  • Rrelease-after

Changes: If invalid sizes were specified for resizing (i.e. string or negative numbers) the script would crash. Resizing of transparent PNG24 files was not working. Working with PNG files would always make the value of the "error" property equal to 5, even if everything went well. When resizing, interpolation was not used and the resulting images were rough. Resizing was not working correctly in some cases. All of these bugs have been fixed. The imagecopyresampled() function is now used instead of imagecopyresized().

  • Rrelease-mid
  •  06 Sep 2006 05:16
  • Rrelease-after

No changes have been submitted for this release.

Bafc69c93f4ab79063856429a4fd6902_thumb

Project Spotlight

BlazeBlogger

A CMS for the command line.

No-screenshot

Project Spotlight

morituri

A CD ripper that aims for accuracy over speed.