ASCII-SPRING Conversion
This window allows the
conversion of geographic files (maps and tables) from other systems to the
ASCII-SPRING format.
The supported formats for
conversion are:
-
E00 -
ArcInfo
-
Shape
File - ArcView
-
MID/MIF -
MapInfo
-
DBF - generates an attribute table and generates a points file if coordinates X and Y are columns of a
".dbf" file.
NOTE: See also the interactive mode
conversion, in a DOS window.
IMPORTANT: For a conversion that is more
adequate to the user's needs one must know that:
-
what types of representations we have on the external data, that
is, points, lines, polygons ortables;
-
unit, projection, and datum
of the external data, for project definition and later import;
-
the
converter will make no conversion of unity, projection or datum. The
values read are written as they are, but in the ASCII-SPRING format;
-
what
SPRING data model is more adequate to the
external data;
-
a
thematic, numeric, cadastral, or network
category should already exist in the database before importing the
representations;
-
an
object category, for maps of the cadastral or network
models can be created during data import, unless there is a need to use
the existing one, in this case that category must be selected;
-
the
file converted to the ASCII-SPRING format must be imported to the project with the bounding box encompassing the data
coordinates.
This converter requires
that a database be loaded, even if the output object category is nonexistent
in the database. The files created during the conversion will be available in
the same origin directory MIF, SHAPE, E00, and DBF.
Converting files to the
ASCII-SPRING format:
-
load
a database;
-
click
on
File - Convert to ASCII SPRING... The window "Conversion ASCII SPRING" will be presented;
-
click
on
File... The window "SPRING of Open File" is presented;
·
select in Directory:
the directory where is the file to be converted;
·
select in Files: one of the formats *.shp, *.dbf,
*.e00 or *.mif;
·
select the file to be converted;
·
click
on
Save;
-
choose in SPRING Model:
one of the categories Thematic, Cadastral, DTM, Network or txt Listing, as destination of the file to be created;
-
in
case the chosen model is Cadastral or Network, click on Object Categories... to choose one from the loaded database. The window
"
Categories
List" is presented. Select
one category from the list and click on Apply. If the
object category does not exist and you still want to convert the data
using some other name, simply edit the data in the dialog box;
-
choose the desired item in the Attributes (Class/Label/Height)
list. This choice depends on the model that was chosen above:
-
if
Thematic: the chosen attribute will represent the
classes of the points, lines, or polygons - the option [NNE] does not
create section POINTS in <file>.spr,
but only the section LINES;
-
if
Cadastral: the chosen attribute will represent the label + name of the object associated to points, lines, and polygons -
the option [NONE] uses an internal identification of the point, line or
polygon to associate with the label + name;
-
if
MNT: the chosen attribute will represent the height of
the contour line or spot height - the option [NONE] associates the
value 0 (zero) to every contour line and point;
-
if
Network: the chosen attribute will represent the label + name of the object associated to lines - the option [NONE] uses
an internal identification of the line to associate to the label + name;
-
if the file is of the
*.dbf
type, choose in the CoordX
/Long list the desired item that contains the
X coordinate or longitude, and choose in the CoordY
/Lat list the desired item
containing the Y coordinate or the latitude.
-
modify, if you like, the name of
the ASCII file to be created;
-
click on Apply to start the conversion.
NOTE: The converted files will be in the same directory
that are home to the original files.
This conversion will
always result in a file with the *.spr
extension, with the possible sections POINT2D, LINES, POINTS, SAMPLE, NETWORK e
NETWORK_OBJECTS, or else the file *_TAB.spr
(when
the conversion is of a cadastral or network) with a
TABLE section.
See following, in the
"Import"window
, to what entity each of these
sections is associated, as a function of the SPRING model:
THEMATIC
-
Points: <file>.spr - contains only the section POINT2D
-
Entity = "
Points" in <file>_P2d.spr
-
Lines: <file>.spr - contains the sections LINES and POINTS in the
same or in different files (L2D and LAB)
-
Entity = "
Lines without Adjustment" in
<file>_L2D.spr
-
Entity = "
Identifiers" in <file>_LAB.spr
-
Polygons: <file>.spr - contains sections LINES and POINTS in the same
or in different files (L2D or LAB)
-
Entity = "
Lines with
Topol."
in <file>_L2D.spr *
-
Entity = "
Identifiers" in <file>_LAB.spr
*: In the case of
polygons we recommend the elimination of the double lines on the neighborhood
of polygons (see the tool Clean Vector)
NOTE: for the three representations the classes are automatically
created during import, in case they do not exist.
CADASTRAL
-
Points: <file>.spr - contains only the section POINT2D +
<file>_TAB.spr - contains only section
TABLE
-
Entity = "
Points" in <file>_P2D.spr
-
Entity = "
Obj/Attributes"
of <file>_TAB.spr
-
Lines: <file>.spr - contains sections LINES and POINTS in the same
file + <file>_TAB.spr - contains section
TABLE
-
Entity = "
Lines without Adjustment" of
<file>_L2D.spr
-
Entity = "
Identifiers" of <file>_LAB.spr
-
Entity = "
Obj/Attributes"
of <file>_TAB.spr
-
Polygons: <file>.spr - contains sections LINES and POINTS in the same
file + <file>_TAB.spr - contains section
TABLE
-
Entity = "
Lines with
Topol."
of <file>_L2D.spr *
-
Entity = "
Identifiers" of <file>_LAB.spr
-
Entity = "
Obj/Attributes"
of <file>_TAB.spr
* : In the case of
polygons it is recommended the elimination of the double lines in the
adjacency of the polygons (see the tool Clean Vector)
NOTE: for the three representations
the object category will be automatically created, with the name provided for
the conversion. On the contrary you can use one of the existing category.
NOTE: in the import of <file>_TAB.spr,
the object attributes will be created automatically when there is no
attribute previously created. On the contrary only the existing attributes
will be updated.
NUMERIC
-
Points (with height): <file>_P3D.spr
- contains only the section SAMPLE and sub-section POINT3D
-
Lines (contour lines):
<file>_L3D.spr - contains only the section SAMPLE and many
sub-sections LINE3D
NETWORKS
-
LinEs (oriented): <file>.spr - contains sections NETWORK and NETWORK_OBJECTS
in the same file + <file>_TAB.spr -
contains section TABLE
-
Entity = "
Lines with Adjustment" of
<file>_L2D.spr
-
Entity = "
Identifiers" of <file>_LAB.spr
-
Entity = "
Obj/Attributes"
of <file>_TAB.spr
NOTE: the object category will be
automatically created, with the name provided during conversion. On the
contrary you could use one of the existing categories.
NOTE: during import of <file>_TAB.spr,
the object attributes will be automatically created when there is no other
previously created attribute. On the contrary only the existing attributes
will be used.
LISTING
-
Listing: <file>_LSTnn.txt - contains the listing of the SHAPEFILE
data (bounding box, coordinates and measure unit of the data)
-
Shape Type = "
Point"
of <file>_LST01.txt
-
Shape Type = "
PolyLine"
of <file>_LST03.txt
-
Shape Type = "
Polygon"
of <file>_LST05.txt
OBS.:
-
See also the web site:
-
http://www.dpi.inpe.br/spring/portugues/conversores.html
Conversion - using a DOS window
Every conversion program
can be used independently of SPRING, it suffices to
open a DOS window and type in the name of the corresponding executable file.
The
"mif2spr.exe" program converts the data from format MIF/MID
(created by MapInfo) to the ASCII-INPE of SPRING.
Options:
Input data:
-
target
category of file SPR: -c = cadastral, -t =
thematic, -s = numeric, -n =
networks.
-
file
name in MapInfo's MIF format or Shapefile's
SHP format, and the output file name.
-
name
of
the file in the spr format (ASCII-SPRING).
-
name
of
an object category, in the cadastral and networks cases.
-
choose
an
attribute - the objective of such a choice depends on the model chosen
above.
-
if
Thematic : the chosen attribute will represent the
classes of points, lines, and polygons - option [0] doesn't create the
section POINTS in file <file>.spr but
only the section LINES;
-
if
Cadastral
: the chosen attribute will represent the label + name of the
object associated to points, lines or polygons to associate with label + name.
-
if
MNT
: the chosen attribute will represent the contour line height or
the spot height - option [0] associates the value 0 (zero) to
every contour line and point.
-
if
Network
: the chosen attribute will represent the label + name of the
object associated to lines - option [0] uses an internal identification
of the line to associate with label + name.
NOTE: The files "*.mif" + "*.mid" or "*.shp" + "*.shx" +
"*.dbf", should be in the same directory.
Output (cadastral case):
IMPORTANT: The programs should be run in a DOS window with the
following syntax:
Command Syntax:
-
mif2spr [-parameter] <mif file>
<spr file>
-
shp2spr [-parameter] <shape file> <spr
file>
where :
[- parameter] could be -c = cadastral, -t =
thematic, -s = numeric, -n = network.
See also:
Database
Definition
Data
Model Definition
How
to IMPORT SGI Data ?
How
to IMPORT GRIB
images
?
How
to IMPORT
Data ?
|