PostGIS  2.5.0dev-r@@SVN_REVISION@@
static void test_geohash_point_as_int ( void  )
static

Definition at line 987 of file cu_algorithm.c.

References geohash_point_as_int(), POINT2D::x, and POINT2D::y.

Referenced by algorithms_suite_setup().

988 {
989  unsigned int gh;
990  POINT2D p;
991  unsigned long long rs;
992 
993  p.x = 50; p.y = 35;
994  gh = geohash_point_as_int(&p);
995  rs = 3440103613;
996  CU_ASSERT_EQUAL(gh, rs);
997  p.x = 140; p.y = 45;
998  gh = geohash_point_as_int(&p);
999  rs = 3982480893;
1000  CU_ASSERT_EQUAL(gh, rs);
1001  p.x = 140; p.y = 55;
1002  gh = geohash_point_as_int(&p);
1003  rs = 4166944232;
1004  CU_ASSERT_EQUAL(gh, rs);
1005 }
double x
Definition: liblwgeom.h:327
double y
Definition: liblwgeom.h:327
unsigned int geohash_point_as_int(POINT2D *pt)
Definition: lwalgorithm.c:647

Here is the call graph for this function:

Here is the caller graph for this function: