ST_SceneFromOSGB

更新时间:
复制 MD 格式

Constructs a scene object from an OpenSceneGraph Binary (OSGB) object stored as bytea.

Syntax

Version 1 — without affine transformation

scene ST_SceneFromOSGB(bytea osgb,
                       integer srid default 0,
                       integer lod default 0)

Version 2 — with affine transformation

scene ST_SceneFromOSGB(bytea osgb,
                       integer srid,
                       integer lod,
                       float8[] affine)

Parameters

ParameterTypeDefaultDescription
osgbbyteaThe OSG object in binary representation.
sridinteger0The spatial reference identifier (SRID).
lodinteger0The Level of Detail (LOD) level.
affinefloat8[]An array of affine transformation values. Must contain exactly 12 or 16 values. See Usage notes for details.

Returns

Returns a value of type scene. A scene object represents a 3D spatial scene and can be passed to spatial query functions such as Box3D.

Usage notes

  • The affine parameter must contain exactly 12 or 16 values.

  • If affine contains 16 values, the last four values are ignored. Only the first 12 values are applied.

Examples

Query the 3D bounding box of a scene constructed from an OSGB binary:

SELECT Box3D(ST_SceneFromOSGB('\xa10e916c4545fb1a0...'));

Output:

                box3d
--------------------------------------------
 BOX3D(-156.239562988281 63.6093330383301 -32.4500007629395,-53.4085960388184 166.440292358398 29.9221706390381)

See also

  • Box3D — returns the 3D bounding box of a geometry or scene object