KML output format?
Frank Warmerdam
warmerdam at POBOX.COM
Thu Jan 4 15:34:04 EST 2007
Daniel Morissette wrote:
> I thought about an OGR driver too, that would be very useful in several
> situations but I had come back to the direct KML output format option
> since that seemed simpler to implement.
Daniel,
I agree.
> Unfortunately for the KML case using OGR to generate the output would
> not allow us to easily apply styles (colors, symbols) to the shapes. We
> would probably need to generate OGR style strings in MapServer to pass
> to the driver and extend the OGR-KML driver to support style strings (I
> assume it doesn't at the moment). There is also the overhead of having
> OGR write the output to disk and then having MapServer read and return
> the contents of the output.
For some drivers (going through VSI*L functions) the output could be
to memory, and then that could be spooled back to stdout after completion.
> Also what to do with formats that generate
> multiple files (e.g. shapefiles, TAB datasets, etc.)? Should MapServer
> zip them up before returning them? And if yes how does MapServer know
> exactly which files to include in the ZIP for each OGR output format?
> Actually, how is this handled at the moment with GDAL output formats?
This is tricky. Currently MapServer GDAL output just doesn't support
multi-file formats. It is my hope to rectify this at some point. It is
a bigger issue for OGR where some key formats (shape, mapinfo) are
multi-file formats.
> An OGR output driver is definitely feasible and means more reusability,
> but that's also more involved than a direct KML output format
> implementation, that's why that was not my preferred option initially.
Agreed
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 | President OSGeo, http://osgeo.org
More information about the mapserver-dev
mailing list