Opened 16 years ago
Closed 14 years ago
#2316 closed enhancement (invalid)
Patch to use libkml for OGR KML reader
Reported by: | Even Rouault | Owned by: | warmerdam |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | OGR_SF | Version: | unspecified |
Severity: | normal | Keywords: | kml libkml |
Cc: | darkblueB, condit, sperkins |
Description
I wanted to test a bit libkml... so here's a patch to current GDAL SVN trunk that uses it for KML reading. I've imported libkml (latest libkml SVN) into ogr/ogrsf_frmts/kml/libkml and minizip into ogr/ogrsf_frmts/kml/minizip. The old Expat reading code is still there. The new libkml-based code is activated by HAVE_LIBKML which is default in the GNUmakefile now.
As I've only modified the GNUmakefile, libkml will only be used on UNIX platforms.
ogr_kml.py is now failing as I've changed the way of naming layers, so that should be fixed.
Libkml is pretty easy to use (the whole reader code fits into ~ 250 lines of code) and it brings easily the capability of reading multigeometry now, as well as KMZ.
There are issues that would need to be solved, such as how to handle properly nested content (I've introduced the convention 'layer0layer1layer2' if layer2 is nested into layer1 which is nested into layer0).
It's also arguable whether we should import libkml and minizip source code into GDAL tree or not.
I will not be able to improve that work for the following 5 weeks, so if people want to go on, they're greatly welcome.
Attachments (1)
Change History (2)
by , 16 years ago
Attachment: | ogr_kml_with_libkml.patch.gz added |
---|
comment:1 by , 14 years ago
Resolution: | → invalid |
---|---|
Status: | new → closed |
Closing as the LIBKML driver is in svn now