Skip to content

How to Generate Animated Webp from a GIF image #210

Answered by jcupitt
AmitSonkhiya asked this question in Q&A
Discussion options

You must be logged in to vote

Could you have two libvipses installed? I tried this:

#!/usr/bin/env php
<?php
require __DIR__ . '/vendor/autoload.php';
use Jcupitt\Vips;

# Vips\Config::setLogger(new Vips\DebugLogger());
$version =  Vips\Config::version();
echo "libvips version $version\n";

$image = Vips\Image::newFromFile("/Users/john/pics/3198.gif", [
    "n" => -1,
    "access" => "sequential"
]);
$image->writeToFile("x.webp");

And it works fine on my mac. That's with libvips from homebrew.

Replies: 3 comments 17 replies

Comment options

You must be logged in to vote
7 replies
@AmitSonkhiya
Comment options

@jcupitt
Comment options

Answer selected by AmitSonkhiya
@jcupitt
Comment options

@AmitSonkhiya
Comment options

@jcupitt
Comment options

@jcupitt
Comment options

Comment options

You must be logged in to vote
8 replies
@jcupitt
Comment options

@jcupitt
Comment options

@AmitSonkhiya
Comment options

@jcupitt
Comment options

@AmitSonkhiya
Comment options

Comment options

You must be logged in to vote
2 replies
@jcupitt
Comment options

@AmitSonkhiya
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants