This topic describes the ST_MeshGeomFromBinary function. This function constructs a meshgeom object from the well-known binary (WKB) representation of the meshgeom object.
Syntax
meshgeom ST_MeshGeomFromBinary(bytea wkb);
meshgeom ST_MeshGeomFromBinary(bytea wkb, int4 srid);Parameters
| Parameter | Description |
|---|---|
| wkt | The meshgeom object in WKB representation. |
| srid | The spatial reference identifier. |
Description
This function constructs a meshgeom object from the WKB representation of the meshgeom object.
Examples
select ST_AsEWKT(ST_MeshGeomFromBinary(ST_AsBinary('MESHGEOM(PATCH(INDEXSURFACE(VERTEX(0 0 2,0 10 3,10 10 1,10 0 1), INDEX((0,1,2),(1,2,3)))))'::meshgeom)));
-----------------------------------------------------------------------------
MESHGEOM(PATCH(INDEXSURFACE(VERTEX(0 0 2,0 10 3,10 10 1,10 0 1),INDEX((0,1,2),(1,2,3)))))