PostGIS 3.7.0dev-r@@SVN_REVISION@@
Loading...
Searching...
No Matches

◆ gserialized2_fast_gbox_p()

int gserialized2_fast_gbox_p ( const GSERIALIZED g,
GBOX box 
)

Read the bounding box off a serialization and fail if it is not already there.

Read the box from the GSERIALIZED or return #LWFAILURE if box is unavailable.

Definition at line 612 of file gserialized2.c.

613{
614 /* Try to just read the serialized box. */
616 {
617 return LW_SUCCESS;
618 }
619 /* No box? Try to peek into simpler geometries and */
620 /* derive a box without creating an lwgeom */
621 else if (gserialized2_peek_gbox_p(g, box) == LW_SUCCESS)
622 {
623 return LW_SUCCESS;
624 }
625 else
626 {
627 return LW_FAILURE;
628 }
629}
static int gserialized2_read_gbox_p(const GSERIALIZED *g, GBOX *gbox)
int gserialized2_peek_gbox_p(const GSERIALIZED *g, GBOX *gbox)
#define LW_FAILURE
Definition liblwgeom.h:96
#define LW_SUCCESS
Definition liblwgeom.h:97

References gserialized2_peek_gbox_p(), gserialized2_read_gbox_p(), LW_FAILURE, and LW_SUCCESS.

Referenced by gserialized_fast_gbox_p().

Here is the call graph for this function:
Here is the caller graph for this function: