[gdal-dev] Re: [FWTools] Re: Style usage?

Stefan Keller sfkeller at gmail.com
Thu Jan 3 19:08:01 EST 2008


Thank you for the explanations. Three supplements:

1. Being able to add user defined styles to KML would be cool, e.g. through
the means suggested in the RFC 18 but also through Virtual Format (VRT)?

2. I stumbled over the STYLEITEM "AUTO" in the UMN MapServer docu:
http://mapserver.gis.umn.edu/docs/howto/ogr_howto/#styleitem-auto-rendering-layers-using-style-information-from-the-ogr-file

This enables that color and style is coming from individual shape objects
(currently MapInfo TAB and DGN only) as opposite to the usual case where
style is defined at the layer level. Idea: I think that if OGR can
pass-through styles on an object basis it's technically not too difficult to
set styles at the layer level (as suggested before).

3. Are there any current applications of OGR styles (for an end user)
besides for MapServer as described above and through the (programmer's) C
API?

-- Stefan

2007/12/28, Daniel Morissette <dmorissette at mapgears.com>:
>
> Stefan Keller wrote:
> >
> > 1. Is there also a concept and a way to change style output in an
> > ogr2ogr call, e.g. for KML?
> >
>
> I don't think ogr2ogr supports "changing" the style assigned to a given
> feature or assigning new styles to features, but when translating
> between formats that support styles ( e.g. TAB, MIF and DGN) then the
> styles are maintained as much as possible.
>
> With respect to KML, last time I checked I don't think the KML driver
> supported styles, so the answer is no, at the moment it is not possible
> to control the style of the features written to KML output (but
> technically that's feasible and could be implemented someday).
>
> > 2. Regarding the style concept perhaps it would be helpful to mention
> > similarities to SLD and eventually also to Mapfile symbols (if there are
> > any)?
> >
>
> The concept of assigning rendering rules to geometries is shared in both
> cases but that's about it. The terminology (pen/brush/etc vs
> symbolizers) and encoding (compact text strings vs verbose XML) are
> completely different.
>
> SLD also supports building up classifications using filter encoding
> which is not part of the OGR style concept.
>
> Why did OGR invent its own encoding instead of reusing SLD? Mostly
> because the OGR style encoding predates the days when SLD became well
> known (to me anyway) and widely used. But even if we were to do this
> again today I'm not sure if we would opt for a verbose XML encoding...
> we'd probably spend a lot of time debating the performance issues vs the
> benefits of interoperability with SLD.
>
> BTW, this question would really belong on the gdal-dev list, so I have
> cross-posted my reply to gdal-dev (and ask that further replies be sent
> only to gdal-dev).
>
> Daniel
> --
> Daniel Morissette
> http://www.mapgears.com/
> _______________________________________________
> FWTools mailing list
> FWTools at lists.maptools.org
> http://lists.maptools.org/mailman/listinfo/fwtools
> http://fwtools.maptools.org/
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/gdal-dev/attachments/20080104/7d44e155/attachment.html


More information about the gdal-dev mailing list