Image type gif – how to save

Notice: This thread is very old.
mrataja
Member | 57
+
0
-

Is it possible to resize either save image type gif without loosing animation?

Filip Procházka
Moderator | 4668
+
0
-

Nette\Image has direct support for gifs, so it might work, but I've never tried it.

mrataja
Member | 57
+
0
-

I`m trying it the way like this, but the static gif picture is saved in the end

$image = NImage::fromFile($_FILES['file']['tmp_name']);
$image->save($arr['pic'], 100, NImage::GIF);
voda
Member | 561
+
0
-

ImageMagick (convert command) has no problem resizing animated gifs. If the layers aren't the same size, then it is best to use percents as units for the resize command. Another alternative I use is convert input.gif -coalesce -resize 100x100 -layers Optimize output.gif. The coalesce option is the important one.

Abigail111
Member | 1
+
0
-

Of course,you can follow the demo method:

public static void SaveImageFile(REImage image, string filePath);
public static void SaveImage image, string filePath, BaseEncoder enc);
 http://www.rasteredge.com/…ng-printing/

Last edited by Abigail111 (2013-08-29 04:41)