The OGR GeoConcept driver treats a single GeoConcept file within
a directory as a dataset comprising layers.
GeoConcept files extensions are .txt
or .gxt
.
Currently the GeoConcept driver only supports multi-polygons, lines and points.
It's an object oriented GIS, where the features are named « objects », and feature types are named « type/subtype » (class allowing inheritance).
Among its import/export formats, it proposes a simple text format named gxt. A gxt file may contain objects from several type/subtype.
GeoConcept text export files should be available for writing and reading.
The OGR GeoConcept driver treats a single GeoConcept file within a
directory as a dataset comprising layers. GeoConcept files extensions
are .txt
or .gxt
.
Currently the GeoConcept driver only supports multi-polygons, lines and points.
.txt
or .gxt
) as a dataset.GeoConcept files can store multiple kinds of geometry (one by layer), even if a GeoConcept layer can only have one kind of geometry.
Note this makes it very difficult to translate a mixed geometry layer from another format into GeoConcept format using ogr2ogr, since ogr2ogr has no support for separating out geometries from a source layer.
GeoConcept sub-type is treated as OGR feature. The name of a layer is therefore
the concatenation of the GeoConcept type name, '.'
and GeoConcept
sub-type name.
GeoConcept type definition (.gct
files) are used for creation only.
GeoConcept feature fields definition are stored in an associated .gct
file, and so fields suffer a number of limitations (FIXME) :
TXT
was used by earlier releases of GeoConcept. GXT
is currently used.
CONFIG=path to the GCT : the GCT file describe the GeoConcept types
definitions : In this file, every line must start with //#
followed by
a keyword. Lines starting with //
are comments.
It is important to note that a GeoConcept export file can hold different types and associated sub-types.
//#SECTION CONFIG
and ends with //#ENDSECTION CONFIG
. All the configuration is enclosed within
these marks.//#SECTION MAP
and ends with //#ENDSECTION MAP
.Name
) and an ID (keyword ID
). A type holds sub-types and
fields.
This section starts with //#SECTION TYPE
and ends with //#ENDSECTION TYPE
.
Name
), an ID (keyword ID
),
a type of geometry (keyword Kind
) and a dimension. The following types of
geometry are supported : POINT, LINE, POLYGON. The current release of this driver does not
support the TEXT geometry. The dimension can be 2D, 3DM or 3D. A sub-type holds fields.
This section starts with //#SECTION SUBTYPE
and ends with //#ENDSECTION SUBTYPE
.
Name
),
an ID (keyword ID
), a type (keyword Kind
). The following types
of fields are supported : INT, REAL, MEMO, CHOICE, DATE, TIME, LENGTH, AREA.
This section starts with //#SECTION FIELD
and ends with //#ENDSECTION FIELD
.Identifier
,
Class
, Subclass
, Name
, NbFields
, X
,
Y
, XP
, YP
, Graphics
, Angle
.Identifier
, Class
, Subclass
,
Name
, X
, Y
.XP
, YP
.Graphics
must be declared.Angle
may be declared.-nln
option.
TYPE
corresponds to one of the Name
found in the GCT file for a type section.
The SUBTYPE
corresponds to one of the Name
found in the GCT file for a
sub-type section within the previous type section.At the present moment, coordinates are written with 2 decimales for cartesian spatial reference systems (including height) or with 9 decimales for geographical spatial reference systems.
//#SECTION CONFIG //#SECTION MAP //# Name=SCAN1000-TILES-LAMB93 //# Unit=m //# Precision=1000 //#ENDSECTION MAP //#SECTION TYPE //# Name=TILE //# ID=10 //#SECTION SUBTYPE //# Name=TILE //# ID=100 //# Kind=POLYGON //# 3D=2D //#SECTION FIELD //# Name=IDSEL //# ID=101 //# Kind=TEXT //#ENDSECTION FIELD //#SECTION FIELD //# Name=NOM //# ID=102 //# Kind=TEXT //#ENDSECTION FIELD //#SECTION FIELD //# Name=WITHDATA //# ID=103 //# Kind=INT //#ENDSECTION FIELD //#ENDSECTION SUBTYPE //#ENDSECTION TYPE //#SECTION FIELD //# Name=@Identifier //# ID=-1 //# Kind=INT //#ENDSECTION FIELD //#SECTION FIELD //# Name=@Class //# ID=-2 //# Kind=CHOICE //#ENDSECTION FIELD //#SECTION FIELD //# Name=@Subclass //# ID=-3 //# Kind=CHOICE //#ENDSECTION FIELD //#SECTION FIELD //# Name=@Name //# ID=-4 //# Kind=TEXT //#ENDSECTION FIELD //#SECTION FIELD //# Name=@X //# ID=-5 //# Kind=REAL //#ENDSECTION FIELD //#SECTION FIELD //# Name=@Y //# ID=-6 //# Kind=REAL //#ENDSECTION FIELD //#SECTION FIELD //# Name=@Graphics //# ID=-7 //# Kind=REAL //#ENDSECTION FIELD //#ENDSECTION CONFIG
//$DELIMITER " " //$QUOTED-TEXT "no" //$CHARSET ANSI //$UNIT Distance=m //$FORMAT 2 //$SYSCOORD {Type: 2001} //$FIELDS Class=TILE;Subclass=TILE;Kind=4;Fields=Private#Identifier Private#Class Private#Subclass Private#Name Private#NbFields IDSEL NOM WITHDATA Private#X Private#Y Private#Graphics -1 TILE TILE TILE 3 000-2007-0050-7130-LAMB93 0 50000.00 7130000.00 4 600000.00 7130000.00 600000.00 6580000.00 50000.00 6580000.00 50000.00 7130000.00 -1 TILE TILE TILE 3 000-2007-0595-7130-LAMB93 0 595000.00 7130000.00 4 1145000.00 7130000.00 1145000.00 6580000.00 595000.00 6580000.00 595000.00 7130000.00 -1 TILE TILE TILE 3 000-2007-0595-6585-LAMB93 0 595000.00 6585000.00 4 1145000.00 6585000.00 1145000.00 6035000.00 595000.00 6035000.00 595000.00 6585000.00 -1 TILE TILE TILE 3 000-2007-1145-6250-LAMB93 0 1145000.00 6250000.00 4 1265000.00 6250000.00 1265000.00 6030000.00 1145000.00 6030000.00 1145000.00 6250000.00 -1 TILE TILE TILE 3 000-2007-0050-6585-LAMB93 0 50000.00 6585000.00 4 600000.00 6585000.00 600000.00 6035000.00 50000.00 6035000.00 50000.00 6585000.00
ogr2ogr -f "Geoconcept" -a_srs "+init=IGNF:LAMB93" -dsco EXTENSION=txt -dsco CONFIG=tile_schema.gct tile.gxt tile.shp -lco FEATURETYPE=TILE.TILEAppending new features to an existing GeoConcept export file :
ogr2ogr -f "Geoconcept" -update -append tile.gxt tile.shp -nln TILE.TILETranslating a GeoConcept export file layer into MapInfo file :
ogr2ogr -f "MapInfo File" -dsco FORMAT=MIF tile.mif tile.gxt TILE.TILE