[Mapserver-users] OGR + DGN STYLEITEM "AUTO" config
Schepel, Menno
menno.schepel at tao.es
Mon Apr 26 10:54:43 PDT 2004
Frank,
Following your suggestion I left out the CLASS info and added the STYLEITEM
"AUTO". This only results in a blank map!
However, adding a CLASS definition using a 'dummy' color (255 255 255 or
whatever color you like) gives a good result. Using an empty class (CLASS
immediately followed by END) does not do the trick. So here is an abstract
of the mapfile used:
LAYER
STATUS ON
GROUP DGN
CONNECTIONTYPE OGR
CONNECTION "C:\inetpub\wwwroot\vinya\data\xarxa_i07.dgn"
NAME "Sorea"
TYPE line
TOLERANCE 10
STYLEITEM "AUTO"
METADATA
WMS_TITLE "Sorea DGN"
WMS_SRS "EPSG:23031"
WMS_EXTENT "420426,55 4591480,93 421308,65 4591676,52"
END
PROJECTION
"init=epsg:23031"
END
CLASS
color 255 255 255
END
END
Best regards,
Menno
-----Mensaje original-----
De: Frank Warmerdam [mailto:warmerdam at pobox.com]
Enviado el: lunes, 26 de abril de 2004 18:27
Para: Schepel, Menno
CC: UMN MapServer
Asunto: Re: [Mapserver-users] OGR + DGN STYLEITEM "AUTO" config
Schepel, Menno wrote:
> LAYER
> STATUS OFF
> GROUP DGN
> CONNECTIONTYPE OGR
> CONNECTION "C:\inetpub\wwwroot\vinya\data\granollersv7.dgn"
> NAME "Granollers"
> TYPE Line
> TOLERANCE 10
> METADATA
> WMS_TITLE "Granollers DGN"
> WMS_SRS "EPSG:23031"
> WMS_GROUP_TITLE "OGR-DGN Test Files"
> END
> PROJECTION
> "init=epsg:23031"
> END
> CLASS
> COLOR 255 0 0
> END
> DUMP TRUE
> TEMPLATE "templates/Granollers.html"
> HEADER "templates/Granollers_header.html"
> FOOTER "templates/Granollers_footer.html"
> END
...
> I have found some examples of using MapInfo files in the forum and on the
> sites of MapServer and DM solutions, but until now I did not see an
example
> using DGN. The manual is mentioning that it should be possible, however.
> What do I have to put in the symbol file in order that it will recognize
the
> different styles used within the DGN?
> Is there someone who has some experience with this that they could share?
> Thanks,
Menno,
In general you should just be able to add STYLEITEM "AUTO" to your layer
definition, and perhaps remove your CLASS definition. This should cause
MapServer to use the OGR style information. There should not be any
changes to symbol files required. I don't think any of the DGN autostyled
stuff uses symbols.
Best regards,
--
---------------------------------------+------------------------------------
--
I set the clouds in motion - turn up | Frank Warmerdam,
warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush | Geospatial Programmer for Rent
More information about the MapServer-users
mailing list