Opened 15 years ago

Last modified 15 years ago

#3004 new defect

Smybol Rotation not working with Map Rotation

Reported by: flavio Owned by: warmerdam@…
Priority: high Milestone:
Component: MapServer C Library Version: 5.4
Severity: normal Keywords: Map Rotation
Cc: dmorissette

Description (last modified by warmerdam)

When defining rotated symbols in MapFile, the rotation is not used when rotating maps. Sample MapFile Section:

            CLASS
                  EXPRESSION "Regel_Mess_Organe.Hydrant.Unterflurhydrant"
                  STYLE
                  COLOR 0 0 0
                  SYMBOL "pumpenschacht"
                  ANGLE [SYMBOLORI]
                  SIZE 65
              END
            END

Attachments (1)

rotation.gif (36.5 KB ) - added by flavio 15 years ago.

Download all attachments as: .zip

Change History (2)

by flavio, 15 years ago

Attachment: rotation.gif added

comment:1 by warmerdam, 15 years ago

Cc: dmorissette added; dmorissette@… removed
Description: modified (diff)
Milestone: 5.4 release

I have confirmed that there seems to be no relationship between the angle in styleObj and the map rotation in map->gt.rotation_angle. On the other hand, the map rotation is applied to label angles before rendering (seen via use of rotation_angle in mapdraw.c with label.angle).

I am not entirely clear how symbol rotation is achieved. I see there is an msRotateSymbol() function called from mapgd.c extensively if style.angle is non-zero. I'm not sure how it is done in other contexts.

I see the original map rotation work was done before we developed the RFC process, otherwise I would suggest updating and revoting the map rotation RFC.

I'm afraid fixing symbol rotation is not something I have time to pursue on my own currently, but I'm willing to provide supporting information on how map rotation works and is applied to labels to anyone willing to work on symbol support. I do think we need to contemplate whether we ought to be applying map rotation automatically to all symbols or not. In the case of labels we only applied the map rotation if the labels had a non-zero angle.

For now I have removed the 5.4 milestone as I don't feel that is realistic. This might either belong in 6.0 or possibly a 5.4 point release.

Note: See TracTickets for help on using tickets.