[Gdal-dev] UK OS Mastermap GML
Roger James
rogerjames99 at btinternet.com
Mon May 5 14:34:57 EDT 2003
Frank,
Thanks for the quick turnaround. I have checked it against my data and
it does what I would expect it to.
I am currently working on Ben's vterrain base to update the feature
import. We both thought it would be a good idea to move to ogr as the
importer of first resort. The new OSGB gml format was one of my test
cases. In the first instance I just wanted to see if I could get OGR to
parse the file!
As you have already surmised, it looks like more work is needed to get a
robust feature import mechanism. From the vtp perspective I think it
would be better if this work was "under the hood" in ogr.
By the way, XSISCHEMA has now appeared in my source tree. I am intrigued
as to why I never saw it before ;-)
Roger
> -----Original Message-----
> From: gdal-dev-admin at remotesensing.org [mailto:gdal-dev-
> admin at remotesensing.org] On Behalf Of Frank Warmerdam
> Sent: 05 May 2003 16:38
> To: gdal-dev at remotesensing.org
> Subject: Re: [Gdal-dev] UK OS Mastermap GML
>
> Roger James wrote:
> > Frank,
> >
> >
> >
> > I have been looking at getting ogr to read the new UK OS Mastermap
GML
> > formats. The current gml reader cannot do this because is does not
> > recognise the OS derived schema. I noticed from some earlier posting
you
> > has been doing something in the gml schema area (you mention an
> > XSISCHEMA schema option), however, this appears to be output only,
and I
> > cannot find any reference to it in the current source!
>
> ...
>
> >
> > I was thinking that a quick hack would be to just change some of the
> > built in schema strings that you scan for. But that seems very
ugly.
>
> Roger,
>
> The main problem with OS Mastermap data is that OGR's GML reader looks
> specifically for featureMember elements to identify features. When I
add
> osgb:cartographicMember to the IsFeature() test, the Mastermap data
seems
> to more or less work.
>
> The work related to XSISCHEMA was really adding a mechanism for
someone
> creating files with GML to add a reference to a previously created
schema
> file. I have also added a bunch of logic to try and create a valid
schema
> on the fly in a .xsd file, though I am not sure whether the result is
> valid.
> Neither of these will help much in reading OS Mastermap data.
>
> I am not exactly sure how to proceed. Currently when OGR reads a GML
file
> it writes out a .gfs file which contains informaton on the schema,
feature
> count and extents so that subsequent reads of the file can skip the
extra
> "exploration" pass, and so metadata will be known from the start. My
> intention was always that .gfs files could also contain various rules
> for reading tricky GML files. So in this OS MasterMap case it might
> contains information on how to identify features (they are children of
> <osgb:cartographicMember>), or allowing renaming and typing of
otherwise
> untyped properties.
>
> The other approach is to add proper schema (.xsd) reading to the OGR
GML
> reader. This would potentially make OGR much more robust as all the
> information actually embedded in the .xsd files could be used to
identify
> features; however, it is very difficult.
>
> What I have done for the time being is modify the code to treat any
> element
> ending in "member" as potentially containing a feature. This works
for
> the
> OS MasterMap data.
>
> I would suggest you try the latest from CVS and see if it is adequate
to
> your needs.
>
> 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
>
>
> _______________________________________________
> Gdal-dev mailing list
> Gdal-dev at remotesensing.org
> http://remotesensing.org/mailman/listinfo/gdal-dev
More information about the Gdal-dev
mailing list