[mapserver-users] change AGG Driver via mapscript

schroeter at netgis.de schroeter at netgis.de
Tue Apr 15 08:17:53 EDT 2008


Hallo,

the standard-output-format in my mapfile is AGG_JPEG:

OUTPUTFORMAT
   NAME "AGG_JPEG"
   DRIVER AGG/JPEG
   IMAGEMODE RGBA
   FORMATOPTION "QUALITY=88"
END

I try to change the outputformat via mapscript to get a transparent 
256-color-png:

   $map->outputformat->set("name", "png");
   $map->outputformat->set('driver','GD/PNG');
   $map->outputformat->set('transparent',MS_ON);

this works fine, but I get a transparent 24 bit png

if I try to set the imagemode:

$map->outputformat->set("imagemode", MS_IMAGEMODE_PC256);

I get no picture but this warning:
PHP Warning:  [MapServer Error]: msImageCreateAGG(): AGG driver only 
supports RGB or RGBA pixel models

how can I disable AGG?

thanks Sven 




More information about the mapserver-users mailing list