performance problem
"Guillaume SUEUR (Géosignal)"
guillaume.sueur at GEOSIGNAL.FR
Tue Dec 28 00:11:34 PST 2004
Sorry, it's the map.h header file you need. It's in your mapserver
source directory. On lines 249 and 250, you have :
#define MS_MAXCLASSES 250
#define MS_MAXSTYLES 5
which means than a layer object can't have more than 250 classes (my
settings here, default is 50) and a class object can't have more than 5
styles.
In mapsymbol.h you have these :
#define MS_MAXSYMBOLS 64 // maximum number of symbols in a
symbol file
#define MS_MAXVECTORPOINTS 100 // shade, marker and line symbol
parameters
#define MS_MAXSTYLELENGTH 10
I think your problem is around here.
The solution is to change these default settings to more appropriate
ones, and rebuild mapserver/mapscript
Good luck then !
joerg pfeiffer wrote:
> ***********************
> Votre mail a étét scanné par InterScan VirusWall.
> ***********-***********
>
>
> unfortunately, I can't find map.c on my Suse 9.1
> and I also can't find more infos to MAX_CLASSES..
>
> Which map.c file do you mean?
> Could you specify it a little bit more? Seems like it's the solution!
>
> Joerg
>
>
> Guillaume SUEUR (Géosignal) wrote:
>
>> it may be a limit of the program itself on the number of shapeObj by
>> example. For an application I'va done, I had to change the MAX_CLASSES
>> value in the map.c file to allow using more than 50 different classes.
>> Same for the symbols, limited to 255 by default.
>>
>> Good luck
>>
>> joerg pfeiffer wrote:
>>
>>> ***********************
>>> Votre mail a étét scanné par InterScan VirusWall.
>>> ***********-***********
>>>
>>>
>>> hello,
>>>
>>> I have a 4000 point track in mysql. I build my trackline with
>>>
>>> $TrackLayerObj = $this->map->getLayerByName('gpstrack');
>>> $pointObj = ms_newPointObj();
>>> $line = ms_newLineObj();
>>>
>>> for($i=0;$i<count($pointlist);$i++){
>>> $lat=$pointlist[$i][0];
>>> $long=$pointlist[$i][1];
>>> $pointObj->setXY($long,$lat);
>>> $line->add($pointObj);
>>> $shp = ms_newShapeObj(MS_SHAPE_LINE);
>>> $shp->add($line);
>>> if($TrackLayerObj->addFeature($shp) == -1){
>>> echo "addFeature in lineLayer failed";
>>> }
>>> }
>>>
>>> If I choose just a few trackpoints, it's no problem. But when I want to
>>> show all 4000, linux 'top' shows php-cgi running and running and then I
>>> get a blank browser site, due to timeout I guess.
>>>
>>> Are 4000 points too much?
>>> Any ideas?
>>>
>>> Joerg
>>>
>>>
>>>
>>>
>>
>
>
>
>
>
--
---------------------------
Guillaume SUEUR
GEOSIGNAL - Groupe BVA
25bis Avenue Marcel Dassault
31505 TOULOUSE CEDEX 5
----------------------------
More information about the MapServer-users
mailing list