[mapserver-users] mapscript php with agg rendering?

Michael Schulz mandschulz at googlemail.com
Tue Feb 15 08:56:07 EST 2011


Hi,

yeah, unfortunately I tried that one already, but it didn't work
either. Although "IMAGETYPE aggpng24" now shows up in the saved
mapfile, but the rendered output is still definitely GD and not AGG.

I found this in trac http://trac.osgeo.org/mapserver/ticket/2813, it's
a bit old but that seems exactly my problem, only the solution doesn't
workforme.

Thx, Michael

2011/2/15 Pavel Iacovlev <iacovlev.pavel at gmail.com>:
> Use the predefined one:
> $map->selectOutputFormat('AGGPNG24');
>
> On Tue, Feb 15, 2011 at 1:37 PM, Michael Schulz <mandschulz at googlemail.com>
> wrote:
>>
>> Hi mapservers,
>>
>> I have a question regarding the AGG rendering when creating a map
>> completly from php-mapscript. In the script I (think I) am setting all
>> the required parameters for the map to be rendered with AGG using
>> 24bit:
>>
>> $oMap=ms_newMapObjFromString("MAP END");
>> ...
>>
>> $oMap->outputformat->set('name','png');
>> $oMap->outputformat->set('driver','AGG/PNG');
>> $oMap->outputformat->set('mimetype','image/png');
>> $oMap->outputformat->set('imagemode',MS_IMAGEMODE_RGBA);
>> $oMap->outputformat->set('extension','png');
>> $oMap->outputformat->set('transparent',MS_TRUE);
>>
>> I've experienced for some time with the following directive, trying to
>> actually invoke the correct outputformat
>> $oMap->selectoutputformat("png");
>>
>> But to no avail. The maps that derive from this script clearly use the
>> GD driver. When I saved the generated map-file to the filesystem I
>> found the following line in the map section:
>>
>> IMAGETYPE gif
>>
>> I am using MapServer, Mapscript 5.6.6., PHP 5.3.3 on OpenSuse 11.3
>>
>> Maybe someone could share some mapscript code or has some hints how to
>> actually return AGG rendered maps.
>>
>> Thanks, Michael
>>
>> --
>> -----------------------------------------------------------
>> Michael Schulz
>> _______________________________________________
>> mapserver-users mailing list
>> mapserver-users at lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/mapserver-users
>
>



-- 
-----------------------------------------------------------
Michael Schulz

Christoph-Mang-Str. 5
D-79100 Freiburg


More information about the mapserver-users mailing list