Jump to content

Animated GIF resize issue


j00st
 Share

Recommended Posts

Hi, 

I'm running into the same problem. My setup is PW 3.0.120 on PHP 8.1. I tried all the recommendations above. There are no errors and log seems fine, but the resized gifs are not animated. The site I'm using it runs for quite a while now and the before the switch to PHP 8 and the latest PW version the resizing of gifs was working fine.

If there are any news on that pleas let me know. Thank you.

Link to comment
Share on other sites

  • 3 months later...

Looks like the core module for resizing animated gifs doesn't work for PHP 8.

On the Production we have PW: 3.0.194 dev and PHP: 7.3.33-10+ubuntu18.04.1+deb.sury.org+1 and it is working there. Is it normal, that a resized animated gif gets bigger? The original was 1mb, the resized one 2mb. And the resized gif also had some 'artefacts/shadows' in it, and it also doesn't changed when adjusting quality from 90 to 100.

array(5) {
  ["filename"]=>
  string(88) "/home/www-data/xxxxxxxxx.net/site/assets/files/205849/xxxxxxx.gif"
  ["extension"]=>
  string(3) "gif"
  ["imageType"]=>
  int(1)
  ["info"]=>
  array(18) {
    ["width"]=>
    int(1200)
    ["height"]=>
    int(627)
    ["imageType"]=>
    int(1)
    ["mime"]=>
    string(9) "image/gif"
    ["orientation"]=>
    int(0)
    ["rotate"]=>
    int(0)
    ["flip"]=>
    int(0)
    ["channels"]=>
    int(3)
    ["bits"]=>
    int(8)
    ["gifversion"]=>
    string(6) "GIF89a"
    ["animated"]=>
    bool(true)
    ["delay"]=>
    int(4)
    ["trans"]=>
    bool(true)
    ["transcolor"]=>
    int(2)
    ["bgcolor"]=>
    int(2)
    ["numcolors"]=>
    int(256)
    ["interlace"]=>
    bool(false)
    ["appmarker"]=>
    array(0) {
    }
  }
  ["iptcRaw"]=>
  NULL
}
array(2) {
  [0]=>
  string(27) "ImageSizerEngineAnimatedGif"
  [1]=>
  string(18) "ImageSizerEngineGD"
}
string(14) "gif-trans-anim"




On the Dev Enviroment we have PW: 3.0.194 and PHP: 8.0.28 and there it isn't working/resizing.

array(5) {
  ["filename"]=>
  string(92) "/home/www-data/xxx.xxxxxx.net/site/assets/files/178453/xxxxxxx.gif"
  ["extension"]=>
  string(3) "gif"
  ["imageType"]=>
  int(1)
  ["info"]=>
  array(18) {
    ["width"]=>
    int(1200)
    ["height"]=>
    int(627)
    ["imageType"]=>
    int(1)
    ["mime"]=>
    string(9) "image/gif"
    ["orientation"]=>
    int(0)
    ["rotate"]=>
    int(0)
    ["flip"]=>
    int(0)
    ["channels"]=>
    int(3)
    ["bits"]=>
    int(8)
    ["gifversion"]=>
    string(6) "GIF89a"
    ["animated"]=>
    bool(true)
    ["delay"]=>
    int(4)
    ["trans"]=>
    bool(true)
    ["transcolor"]=>
    int(2)
    ["bgcolor"]=>
    int(2)
    ["numcolors"]=>
    int(256)
    ["interlace"]=>
    bool(false)
    ["appmarker"]=>
    array(0) {
    }
  }
  ["iptcRaw"]=>
  NULL
}
array(2) {
  [0]=>
  string(27) "ImageSizerEngineAnimatedGif"
  [1]=>
  string(18) "ImageSizerEngineGD"
}
string(14) "gif-trans-anim"


 

Link to comment
Share on other sites

  • 8 months later...

Any news on that front? I have an images field on a page with a CKEditor field. When I add to that text content a gif from the images field, the gif gets resized and is not animated. I understand this is a bug that is yet to be fixed but is there a workaround in the meantime? Since I'm not displaying the images programmatically I cannot use the API e.g. Pageimage::getOriginal()  

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...