PostGIS  2.5.1dev-r@@SVN_REVISION@@

◆ lwgeom_as_lwtriangle()

LWTRIANGLE* lwgeom_as_lwtriangle ( const LWGEOM lwgeom)

Definition at line 215 of file lwgeom.c.

References TRIANGLETYPE, and LWGEOM::type.

Referenced by extract_pointarrays_from_lwgeom(), LWGEOM_dumppoints(), LWGEOM_exteriorring_polygon(), and lwgeom_swap_ordinates().

216 {
217  if ( lwgeom == NULL ) return NULL;
218  if ( lwgeom->type == TRIANGLETYPE )
219  return (LWTRIANGLE *)lwgeom;
220  else return NULL;
221 }
#define TRIANGLETYPE
Definition: liblwgeom.h:97
uint8_t type
Definition: liblwgeom.h:398
Here is the caller graph for this function: