FREEFORM DATA TYPES IN SPATIAL DATABASE
CONVERSI0N FUNCTIONS
Several functions are created
on the new data types. The
first group of functions
relates to basic transformation
functions: 'translation',
'rotation', 'scale'. Because of
the projective invariant
property of Bezier/Bspline/
NURBS, the transformation
of these curves and
surfaces can be just done by
applying the transformation
to their control points. No
further change is needed.
The second group is cocalled
conversion functions.
Because NURBS are the generalization
of B-spline and
Bezier, it is rather simple to
convert from B-spline and
Bezier to NURBS. Furthermore,
because GIS doesn't
support freeform geometry,
the conversions
from Bezier/Bspline/
NURBS to
simple shapes are
necessary. We
have implemented
two such functions
in this
research; they are
a drop function to
convert a NURBS
curve to line
strings, and a
mesh function to
convert a NURBS
surface to polygons
and triangles.
Third group of
functions provide
allow for creation of new
geometry types such as centroid,
convex hull and
bounding box. Another
group of functions compute
a distance and check for
intersection between two
geometries (the function
anyintersect is implemented
on the convex hull of the
geometries). Currently, some
of the functions return
approximation results
instead of accurate results,
because this way the algorithms
are easier and computation
are faster. Calculation
of accurate centroid of
freeform geometry, or accurate
intersection between
freeform geometry, could be
very complex and heavy,
therefore the accurate calculation
functions are excluded
from database as discussed
earlier. Some examples
of such functions are
listed below:
SQL> select id, VALIDATION(A.geom)
from test_table A;
ID A.GEOM.VALIDATION()
---------- ------------------
1 0 --- Correct entry
2 -1 --- Storage invalid
3 -2 --- Geometry invalid
SQL> select distance(A.geom,B.geom) from test_table A, test_table B where A.id=3 and B.id=5; DISTANCE(A.GEOM,B.GEOM)
---------------------
558.859116


Figure 3.A building cluster
(left: CAD model in MicroStation;
right: GIS model in ArcGIS)
VISUALIZATION
Using these data types complex
models containing
freeform curves and surfaces
can be created and edited in
a CAD application and stored
in DBMS. The transformation
function to simple
geometry allows for conversion
into simple geometries
(i.e. freeforms are converted
in triangulated surfaces) and
concequently visualization
in a GIS application. Generally
this approach allows for
integration of complex and
simple shapes at database
level. Points, lines and polygons
of a model are stored in
the simple geometry column
with SDO_Geometry, and
freeform shapes are stored
in the complex geometry
column with our new data
type. Various other attributes
such as ID, name,
colour, owner, etc. can be
also appropriately organized
the same database.
When CAD applications
request model data from
DBMS, simple shapes from
the simple geometry column
and freeform shapes from
the freeform column are
retrieved and visualized
directly according to their
geometry type, as CAD
applications supports all
these geometry types. All
the import and export operations
can be implemented in
the development environments
provided by CAD
applications. If a GIS application
access the data, it uses
only the simple data types.
The complex geometry types
are converted by the corresponding
function to simple
object (lines and triangles).
Note this operation can not
be reversed. Therefore the
freeform geometries can be
only visualized in GIS application
but not edited.
Figure 2 and 3 shows complex
freeform curves and
surfaces in CAD and GIS
application. The CAD model
contains on Figure 3 contains
line strings, polygons
and some NURBS surfaces.
Note the two roofs in Figure
3 left are two NURBS surfaces,
and in right are actually
several polygons.
CONCLUSIONS AND RECOMMENDATIONS
We have shown that NURBS
is a very general representation
of freeform shapes, and
we recommend considering
its inclusion in the Implementation
specifications of
OGC. NURBS, Bézier and Bsplines
are already recognized
in the CAD domain as
flexible geometries for modelling
complex shapes and it
is not difficult to be supported
by DBMS. Tests have convincingly demonstrated that
appropriate data types for
efficient management of
freeform curves and surfaces
can be created at DBMS level.
Oracle Spatial 11g already
allows storage of such
shapes but none of the geometric
functions support
them.
This research is only the
first step toward managing
freeform data types in a spatial
DBMS and GIS. Many
issues have to be investigated
further. For example, the
validation rules for freeform
curves and surfaces have to
be specified in more detail.
The current implementation
of validation functions is
derived directly from the
mathematical definitions.
Further research is needed
to determine relevant functions
for support at DBMS
level. The implemented set
of prototype functions is relatively
basic and not sufficient.
For example, the function
AnyIntersect uses the
convex hulls of the control
points of two shapes to
investigate possible intersections.
More accurate conclusions
on the intersection
of the shapes would require
exhaustive computations.
Separate data type for error
messages would be very
valuable, since the freeform
shapes are much more complex
than the simple features.
It can be included as
an error number attribute
and an error message attribute
within the data type.
Although NURBS can represent
conic sections (circle,
ellipse, hyperbola, parabola),
separate data types still
have to be designed to represent
these simple shapes in
their simplest form. The
parameters needed to store,
for example, a circle as a
NURBS shape are considerable.
This research did not
consider indexing of
freeform shapes. As is well
known, a spatial index can
make spatial queries much
more efficient.
The current DBMS spatial
indexing mechanism works
on existing simple geometries
and cannot be used for
prototype data types. Further
investigations are needed
to develop. The data types
do not yet resolve the problems
of modelling of
freeform shapes in GIS applications.
Currently, the only
possibility is to approximate
freeform shapes with simple
features (sets of lines and
polygons) for visualization
with 3D GIS models. Alternatively,
the traditional GIS
models stored in DBMS can
be integrated with CAD
freeform models and further
explored (and modelled) in
CAD applications. In this
manner, the first real integration
of typical CAD
shapes with GIS shapes can
be realized.