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

◆ lwpoint_set_ordinate()

void lwpoint_set_ordinate ( POINT4D p,
char  ordinate,
double  value 
)
inline

Given a point, ordinate number and value, set that ordinate on the point.

Definition at line 283 of file lwlinearreferencing.c.

284{
285 if (!p)
286 {
287 lwerror("Null input geometry.");
288 return;
289 }
290
291 switch (ordinate)
292 {
293 case 'X':
294 p->x = value;
295 return;
296 case 'Y':
297 p->y = value;
298 return;
299 case 'Z':
300 p->z = value;
301 return;
302 case 'M':
303 p->m = value;
304 return;
305 }
306 lwerror("Cannot set %c ordinate.", ordinate);
307 return;
308}
void void lwerror(const char *fmt,...) __attribute__((format(printf
Write a notice out to the error handler.
int value
Definition genraster.py:62
double m
Definition liblwgeom.h:414
double x
Definition liblwgeom.h:414
double z
Definition liblwgeom.h:414
double y
Definition liblwgeom.h:414

References lwerror(), POINT4D::m, POINT4D::x, POINT4D::y, and POINT4D::z.

Referenced by point_interpolate(), and test_lwpoint_set_ordinate().

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