Fatal error: call to undefined function imagefilter()

This and a number of other gd functions are not available by default in Ubuntu Server LAMP setup. Not trivial, but a valid solution can be found here: http://cumu.li/2008/5/13/recompiling-php5-with-bundled-support-for-gd-on-ubuntu

Problem:

Fatal error: call to undefined function imagefilter()
Complete list of missing functions:
function imageantialias
function imagecolormatch
function imageconvolution
function imagecreatefromxbm
function imagecreatefromxpm
function imagefilter
function imagelayereffect
function imagerotate
function imagexbm

Reason:

GD library hasn’t seen a new release for quite a while, while PHP sources include a bundled GD that’s up-to-date.

Debian/Ubuntu folks have strong technical arguments not to have a PHP package compiled with bundled GD in their repositories.

Solution:

Recompile PHP package with bundled version of GD. Nice instructions can be found here: http://cumu.li/2008/5/13/recompiling-php5-with-bundled-support-for-gd-on-ubuntu

This entry was posted in Software Development and tagged , . Bookmark the permalink.

6 Responses to Fatal error: call to undefined function imagefilter()

  1. Pingback: Graiwas Blog » Blog Archive » call to undefined function imageconvolution

  2. mastanto says:

    Thanks for the link. Very helpful. It’s boring and stressful using php without full GD-library support..

  3. Pingback: call to undefined function imageconvolution | Graiwas

  4. Eric says:

    Hello,
    I experience the same issue today but unfortunately the link given in the “solution” is dead.
    Is there another page on which we can find the detailled instructions?
    Thank you in advance.
    Cheers.
    Eric

  5. v. says:

    Here is a possible alternative. I didn’t try to follow the instructions though:
    http://www.howtoforge.com/recompiling-php5-with-bundled-support-for-gd-on-ubuntu

  6. v. says:

    It’s also worth mentioning that imagemagick library doesn’t have such constraints, so if Ubuntu is required, and gd2 is not, it’s much easier to use it instead.

Leave a Reply

Your email address will not be published. Required fields are marked *