Here is how you can get the delay between the frames in gif file:
<?php
$animation = new Imagick("file.gif");
foreach ($animation as $frame) {
$delay = $animation->getImageDelay();
echo $delay;
}
?>(PECL imagick 2, PECL imagick 3)
Imagick::getImageDelay β ΠΠΎΠ·Π²ΡΠ°ΡΠ°Π΅Ρ Π·Π°Π΄Π΅ΡΠΆΠΊΡ ΠΈΠ·ΠΎΠ±ΡΠ°ΠΆΠ΅Π½ΠΈΡ
ΠΠΎΠ·Π²ΡΠ°ΡΠ°Π΅Ρ Π·Π°Π΄Π΅ΡΠΆΠΊΡ ΠΈΠ·ΠΎΠ±ΡΠ°ΠΆΠ΅Π½ΠΈΡ.
Π‘ΠΈΠ³Π½Π°ΡΡΡΠ° ΡΡΠ½ΠΊΡΠΈΠΈ Π½Π΅ ΡΠΎΠ΄Π΅ΡΠΆΠΈΡ ΠΏΠ°ΡΠ°ΠΌΠ΅ΡΡΠΎΠ².
ΠΠΎΠ·Π²ΡΠ°ΡΠ°Π΅Ρ Π·Π°Π΄Π΅ΡΠΆΠΊΡ ΠΈΠ·ΠΎΠ±ΡΠ°ΠΆΠ΅Π½ΠΈΡ.
Π€ΡΠ½ΠΊΡΠΈΡ Π²ΡΠ±ΡΠ°ΡΡΠ²Π°Π΅Ρ ΠΈΡΠΊΠ»ΡΡΠ΅Π½ΠΈΠ΅ ImagickException, Π΅ΡΠ»ΠΈ Π²ΠΎΠ·Π½ΠΈΠΊΠ»Π° ΠΎΡΠΈΠ±ΠΊΠ°.
Here is how you can get the delay between the frames in gif file:
<?php
$animation = new Imagick("file.gif");
foreach ($animation as $frame) {
$delay = $animation->getImageDelay();
echo $delay;
}
?>