PostGIS  2.3.8dev-r@@SVN_REVISION@@

◆ test_lwpoint_set_ordinate()

static void test_lwpoint_set_ordinate ( void  )
static

Definition at line 398 of file cu_algorithm.c.

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

Referenced by algorithms_suite_setup().

399 {
400  POINT4D p;
401 
402  p.x = 0.0;
403  p.y = 0.0;
404  p.z = 0.0;
405  p.m = 0.0;
406 
407  lwpoint_set_ordinate(&p, 'X', 1.5);
408  CU_ASSERT_EQUAL( p.x, 1.5 );
409 
410  lwpoint_set_ordinate(&p, 'M', 2.5);
411  CU_ASSERT_EQUAL( p.m, 2.5 );
412 
413  lwpoint_set_ordinate(&p, 'Z', 3.5);
414  CU_ASSERT_EQUAL( p.z, 3.5 );
415 
416 }
double x
Definition: liblwgeom.h:351
double m
Definition: liblwgeom.h:351
void lwpoint_set_ordinate(POINT4D *p, char ordinate, double value)
Given a point, ordinate number and value, set that ordinate on the point.
double z
Definition: liblwgeom.h:351
double y
Definition: liblwgeom.h:351
Here is the call graph for this function:
Here is the caller graph for this function: