[Mapserver-users] symbol question

Vladimir Guzmán bigfoot at main-task.com
Fri Jul 9 20:10:32 EDT 2004


fx:

I'm sorry, I had the idea that it was only possible with mapscript, but 
It is not.

Well, as far as I know, there is no way, at the moment, to rotate 
symbols based on an attribute.
So, I had to go trough a workaround:
I have my gps data in postgis this way:
gps_geom: geometry with lat/long
rumbo: angle from north (0 - 360)

My .map:
--------------------------------------------------
    LAYER
        NAME "puntosgps"
        CONNECTIONTYPE postgis
        CONNECTION "user=user password=password dbname=dbname host=host"
        DATA "gps_geom from (select gid,'>'::text as 
sentido,360-rumbo+90 as rumbo,gps_geom,oid from gps_vehi) as foo using 
unique gid using srid=1"
        TYPE POINT
        LABELANGLEITEM 'rumbo'
        LABELITEM 'sentido'
    END
--------------------------------------------------

So, you can not draw a symbol (triangle in your case), but you can draw 
the character '>' showing the car's orientation.
(Or maybe another special truetype symbol)

The result is something like:
http://maintask.com/test1.png
(With an extra classification based on velocity)

Hope that helps,

-- 
Vladimir Ilich Guzmán R.
------------------------
http://maintask.com 


fx gamoy wrote:

>yes i am using mapscript
>i ve already developped a function wich calculate each triangle but i think
>there is better to do
>what's your mind?
>fx
>----- Original Message -----
>From: "Vladimir Guzmán" <bigfoot at main-task.com>
>To: "fx gamoy" <fx.gamoy at mapxplore.com>
>Cc: <mapserver-users at lists.gis.umn.edu>
>Sent: Friday, July 09, 2004 10:38 PM
>Subject: Re: [Mapserver-users] symbol question
>
>
>  
>
>>fx gamoy wrote:
>>
>>    
>>
>>>Hello world,
>>>i'd like to obtain lines with oriented triangle in order to show the
>>>direction of a track.
>>>I have made several test but nothing very interesting..
>>>thanks in advance..
>>>fx
>>>      
>>>
>>Are you using mapscript?
>>
>>--
>>Vladimir Ilich Guzmán R.
>>------------------------
>>http://maintask.com
>>
>>_______________________________________________
>>Mapserver-users mailing list
>>Mapserver-users at lists.gis.umn.edu
>>http://lists.gis.umn.edu/mailman/listinfo/mapserver-users
>>
>>    
>>
>
>_______________________________________________
>Mapserver-users mailing list
>Mapserver-users at lists.gis.umn.edu
>http://lists.gis.umn.edu/mailman/listinfo/mapserver-users
>
>
>  
>





More information about the mapserver-users mailing list