PostGIS  2.5.7dev-r@@SVN_REVISION@@

◆ lwpoint_make2d()

LWPOINT* lwpoint_make2d ( int  srid,
double  x,
double  y 
)

Definition at line 163 of file lwpoint.c.

164 {
165  POINT4D p = {x, y, 0.0, 0.0};
166  POINTARRAY *pa = ptarray_construct_empty(0, 0, 1);
167 
168  ptarray_append_point(pa, &p, LW_TRUE);
169  return lwpoint_construct(srid, NULL, pa);
170 }
POINTARRAY * ptarray_construct_empty(char hasz, char hasm, uint32_t maxpoints)
Create a new POINTARRAY with no points.
Definition: ptarray.c:70
int ptarray_append_point(POINTARRAY *pa, const POINT4D *pt, int allow_duplicates)
Append a point to the end of an existing POINTARRAY If allow_duplicate is LW_FALSE,...
Definition: ptarray.c:156
#define LW_TRUE
Return types for functions with status returns.
Definition: liblwgeom.h:76
LWPOINT * lwpoint_construct(int srid, GBOX *bbox, POINTARRAY *point)
Definition: lwpoint.c:129

References LW_TRUE, lwpoint_construct(), ptarray_append_point(), ptarray_construct_empty(), pixval::x, and pixval::y.

Referenced by _lwt_FindFaceContainingRing(), BOX2D_to_LWGEOM(), cart_to_lwpoint(), geography_centroid_from_mline(), geography_point_outside(), lw_dist2d_distanceline(), lw_dist2d_distancepoint(), LWGEOM_envelope(), LWGEOM_makepoint(), lwmpoint_median(), lwpoly_to_points(), point_from_geohash(), point_to_geometry(), rt_raster_get_convex_hull(), rt_raster_get_envelope_geom(), ST_MinimumBoundingCircle(), ST_MinimumBoundingRadius(), and test_kmeans().

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