Copy over webp animation in gif

This commit is contained in:
Essem 2022-06-28 15:09:30 -05:00
parent 8536c4b968
commit c01ac7d32f
No known key found for this signature in database
GPG Key ID: 7D497397CC3A2A8C
1 changed files with 3 additions and 2 deletions

View File

@ -20,8 +20,9 @@ Napi::Value ToGif(const Napi::CallbackInfo &info) {
} else {
VOption *options = VImage::option()->set("access", "sequential");
VImage in =
VImage::new_from_buffer(data.Data(), data.Length(), "", options);
VImage in = VImage::new_from_buffer(data.Data(), data.Length(), "",
type == "webp" ? options->set("n", -1)
: options);
void *buf;
size_t length;