View Single Post
Old 10-09-2008, 12:45 PM   #6 (permalink)
sketchMedia
The Prestige
Advanced Programmer Top Contributor Good Samaritan 
 
sketchMedia's Avatar
 
Join Date: Oct 2007
Location: Manchester, UK
Posts: 854
Thanks: 32
sketchMedia is on a distinguished road
Default

TIFF can be a container format for images and one of the encoding types of TIFF is JPEG aswel as large 300+ DPI vector images for print etc.

Anyway, Salathe has one solution although i dunno how it would fair if a TIFF was used, as there isn't a TIFF function in PHP's GD API.

You could also use imagemagick, if you have a *nix box with it installed, you can do this:
PHP Code:
exec('convert image.tif image.png'); 
That will convert the image.tif (which is a TIFF) to a png called image.png in the current directory.

You can even do the conversion and resize all in one:
PHP Code:
exec('convert image.tif -resize 200x200 image.png'); 
__________________
mysql> SELECT * FROM `users` WHERE `users`.`clue` > 0;
Empty set (0.00 sec)

Last edited by sketchMedia : 10-09-2008 at 01:14 PM. Reason: Dreadful spelling
sketchMedia is offline  
Reply With Quote