[gdal-dev] allow gml driver to check supported version
Even Rouault
even.rouault at spatialys.com
Wed Jul 15 05:56:10 PDT 2015
On Wednesday 15 July 2015 14:38:06 Martin Landa wrote:
> Hi all,
>
> VFR format is read in GDAL using GML driver together with GFS files
> which are part of GDAL distribution (data/ruian_vf_ob_v1.gfs
> data/ruian_vf_st_uvoh_v1.gfs data/ruian_vf_st_v1.gfs
> data/ruian_vf_v1.gfs). What is missing is version check to inform user
> that GDAL doesn't support the newest version (which is now VFR 1.6).
> This information is stored in VFR header, see example bellow.
>
> <vf:Hlavicka><vf:VerzeVFR>1.6</vf:VerzeVFR><vf:TypZaznamu>Platne</vf:TypZazn
> amu>...</vf:Hlavicka>.
>
> Would be possible to customize GML driver to support such feature? I
> would like to add message like:
Martin,
if you can detect that by just direct string matching, and that the VFR header
is in the 4096 bytes, it shoud be rather easy to add that in
OGRGMLDataSource::Open(). If it might be later, but you can detect that its
VFR, then you might need to ingest more bytes.
If the actual XML content might have variation due to whitespace etc, then
you'll need to go to the hard way and hack into gmlhandler.cpp
Even
>
> Input VFR file is version 1.6, GDAL doesn't support VFR version 1.5
>
> Thanks, Martin
--
Spatialys - Geospatial professional services
http://www.spatialys.com
More information about the gdal-dev
mailing list