1
0
mirror of https://github.com/Intervention/image.git synced 2025-08-21 13:11:18 +02:00

Normalized delay

This commit is contained in:
Oliver Vogel
2021-10-21 16:33:25 +02:00
parent 2927abf1a2
commit 26a35946f1

View File

@@ -47,7 +47,7 @@ class BinaryImageDecoder extends AbstractDecoder implements DecoderInterface
$splitter = GifSplitter::create($gif)->split(); $splitter = GifSplitter::create($gif)->split();
$delays = $splitter->getDelays(); $delays = $splitter->getDelays();
foreach ($splitter->coalesceToResources() as $key => $gd) { foreach ($splitter->coalesceToResources() as $key => $gd) {
$image->addFrame((new Frame($gd))->setDelay($delays[$key])); $image->addFrame((new Frame($gd))->setDelay($delays[$key] / 100));
} }
return $image; return $image;