Format
SDO_TIN_PKG.TO_GEOMETRY( pts IN BLOB, trs IN BLOB, num_pts IN NUMBER, num_trs IN NUMBER, tin_ind_dim IN NUMBER, tin_tot_dim IN NUMBER, srid IN NUMBER DEFAULT NULL, blk_domain IN SDO_ORGSCL_TYPE DEFAULT NULL, get_ids IN NUMBER DEFAULT NULL ) RETURN SDO_GEOMETRY;
Description
Returns a geometry object representing all or part of a TIN.
Parameters
BLOB containing points.
BLOB containing triangles.
Maximum number of points to be included in the resulting geometry.
Maximum number of triangles to be included in the resulting geometry.
Number of spatial dimensions that are indexed.
Number of spatial dimensions defined for the data.
Spatial reference (coordinate system) ID associated with the data. If this parameter is null, no SRID value is associated with the data.
(Not currently used.)
Null or 0 (the default) does not include the block ID and point ID for each point in the returned geometry; 1 includes the block ID and point ID for each point in the returned geometry. If get_ids
is 1, each point in the returned geometry has its spatial dimensions and two additional dimensions. For example: (x, y, z, blk_id, pt_id).
Usage Notes
This function returns a single collection SDO_GEOMETRY object that represents all point geometries in the pts
parameter and all triangle geometries in the trs
parameter. For example, the points and triangles could reflect the result of a clip operation or the contents of an entire block.
Modeling Surfaces describes how to use TINs to model surfaces.
Examples
The following example returns a multipoint collection geometry object representing a TIN. It is taken from the $ORACLE_HOME/md/demo/TIN/examples/plsql/tin.sql
example program, which is available if you installed the files from the Oracle Database Examples media (see Oracle Database Examples Installation Guide).
. . . -- Return points in blk_id of the TIN as a multipoint collection. select sdo_tin_pkg.to_geometry( a.points, -- point LOB a.triangles, -- point LOB a.num_points, -- # of points in the LOB a.num_triangles, -- # of points in the LOB 2, -- index dimensionality (gtype dim in extent in INIT) 3, -- total dimensionality null -- SRID ) from blktab a where blk_id=0; . . .