24 #include "CUnit/Basic.h"
48 CU_ASSERT(rast1 != NULL);
53 CU_ASSERT(band1 != NULL);
61 CU_ASSERT_EQUAL(nodata, 0);
69 CU_ASSERT_NOT_EQUAL(result, 1);
83 CU_ASSERT(rast2 != NULL);
87 CU_ASSERT(band2 != NULL);
95 CU_ASSERT_EQUAL(nodata, 0);
103 CU_ASSERT_EQUAL(result, 1);
111 CU_ASSERT_EQUAL(result, 1);
132 CU_ASSERT_NOT_EQUAL(result, 1);
154 CU_ASSERT_EQUAL(result, 1);
177 CU_ASSERT_NOT_EQUAL(result, 1);
201 CU_ASSERT_NOT_EQUAL(result, 1);
227 CU_ASSERT_NOT_EQUAL(result, 1);
254 CU_ASSERT_NOT_EQUAL(result, 1);
275 CU_ASSERT_NOT_EQUAL(result, 1);
293 CU_ASSERT(rast2 != NULL);
297 CU_ASSERT(band2 != NULL);
310 CU_ASSERT_EQUAL(nodata, 0);
318 CU_ASSERT_EQUAL(result, 1);
351 CU_ASSERT_NOT_EQUAL(result, 1);
382 CU_ASSERT_EQUAL(result, 1);
413 CU_ASSERT_NOT_EQUAL(result, 1);
444 CU_ASSERT_NOT_EQUAL(result, 1);
451 CU_ASSERT(rast2 != NULL);
456 CU_ASSERT(band2 != NULL);
474 CU_ASSERT_EQUAL(result, 1);
485 CU_ASSERT_EQUAL(result, 1);
496 CU_ASSERT_EQUAL(result, 1);
523 CU_ASSERT(rast1 != NULL);
528 CU_ASSERT(band1 != NULL);
536 CU_ASSERT_EQUAL(nodata, 0);
544 CU_ASSERT_NOT_EQUAL(result, 1);
558 CU_ASSERT(rast2 != NULL);
562 CU_ASSERT(band2 != NULL);
570 CU_ASSERT_EQUAL(nodata, 0);
578 CU_ASSERT_NOT_EQUAL(result, 1);
586 CU_ASSERT_NOT_EQUAL(result, 1);
607 CU_ASSERT_EQUAL(result, 1);
629 CU_ASSERT_NOT_EQUAL(result, 1);
652 CU_ASSERT_EQUAL(result, 1);
676 CU_ASSERT_NOT_EQUAL(result, 1);
702 CU_ASSERT_NOT_EQUAL(result, 1);
728 CU_ASSERT_EQUAL(result, 1);
754 CU_ASSERT_EQUAL(result, 1);
781 CU_ASSERT_NOT_EQUAL(result, 1);
802 CU_ASSERT_NOT_EQUAL(result, 1);
820 CU_ASSERT(rast2 != NULL);
824 CU_ASSERT(band2 != NULL);
837 CU_ASSERT_EQUAL(nodata, 0);
845 CU_ASSERT_NOT_EQUAL(result, 1);
878 CU_ASSERT_NOT_EQUAL(result, 1);
909 CU_ASSERT_NOT_EQUAL(result, 1);
940 CU_ASSERT_EQUAL(result, 1);
971 CU_ASSERT_EQUAL(result, 1);
978 CU_ASSERT(rast2 != NULL);
983 CU_ASSERT(band2 != NULL);
1000 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1001 CU_ASSERT_NOT_EQUAL(result, 1);
1011 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1012 CU_ASSERT_NOT_EQUAL(result, 1);
1022 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1023 CU_ASSERT_NOT_EQUAL(result, 1);
1050 CU_ASSERT(rast1 != NULL);
1055 CU_ASSERT(band1 != NULL);
1063 CU_ASSERT_EQUAL(nodata, 0);
1070 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1071 CU_ASSERT_EQUAL(result, 1);
1085 CU_ASSERT(rast2 != NULL);
1089 CU_ASSERT(band2 != NULL);
1097 CU_ASSERT_EQUAL(nodata, 0);
1104 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1105 CU_ASSERT_NOT_EQUAL(result, 1);
1112 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1113 CU_ASSERT_NOT_EQUAL(result, 1);
1133 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1134 CU_ASSERT_NOT_EQUAL(result, 1);
1155 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1156 CU_ASSERT_NOT_EQUAL(result, 1);
1178 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1179 CU_ASSERT_NOT_EQUAL(result, 1);
1202 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1203 CU_ASSERT_NOT_EQUAL(result, 1);
1228 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1229 CU_ASSERT_NOT_EQUAL(result, 1);
1254 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1255 CU_ASSERT_NOT_EQUAL(result, 1);
1280 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1281 CU_ASSERT_NOT_EQUAL(result, 1);
1307 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1308 CU_ASSERT_EQUAL(result, 1);
1328 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1329 CU_ASSERT_EQUAL(result, 1);
1347 CU_ASSERT(rast2 != NULL);
1351 CU_ASSERT(band2 != NULL);
1364 CU_ASSERT_EQUAL(nodata, 0);
1371 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1372 CU_ASSERT_NOT_EQUAL(result, 1);
1404 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1405 CU_ASSERT_NOT_EQUAL(result, 1);
1435 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1436 CU_ASSERT_NOT_EQUAL(result, 1);
1466 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1467 CU_ASSERT_NOT_EQUAL(result, 1);
1497 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1498 CU_ASSERT_NOT_EQUAL(result, 1);
1505 CU_ASSERT(rast2 != NULL);
1510 CU_ASSERT(band2 != NULL);
1527 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1528 CU_ASSERT_NOT_EQUAL(result, 1);
1538 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1539 CU_ASSERT_NOT_EQUAL(result, 1);
1549 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1550 CU_ASSERT_NOT_EQUAL(result, 1);
1577 CU_ASSERT(rast1 != NULL);
1582 CU_ASSERT(band1 != NULL);
1590 CU_ASSERT_EQUAL(nodata, 0);
1597 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1598 CU_ASSERT_NOT_EQUAL(result, 1);
1612 CU_ASSERT(rast2 != NULL);
1616 CU_ASSERT(band2 != NULL);
1624 CU_ASSERT_EQUAL(nodata, 0);
1631 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1632 CU_ASSERT_NOT_EQUAL(result, 1);
1639 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1640 CU_ASSERT_NOT_EQUAL(result, 1);
1660 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1661 CU_ASSERT_NOT_EQUAL(result, 1);
1682 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1683 CU_ASSERT_NOT_EQUAL(result, 1);
1705 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1706 CU_ASSERT_NOT_EQUAL(result, 1);
1729 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1730 CU_ASSERT_NOT_EQUAL(result, 1);
1755 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1756 CU_ASSERT_NOT_EQUAL(result, 1);
1781 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1782 CU_ASSERT_NOT_EQUAL(result, 1);
1807 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1808 CU_ASSERT_NOT_EQUAL(result, 1);
1834 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1835 CU_ASSERT_EQUAL(result, 1);
1855 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1856 CU_ASSERT_EQUAL(result, 1);
1874 CU_ASSERT(rast2 != NULL);
1878 CU_ASSERT(band2 != NULL);
1891 CU_ASSERT_EQUAL(nodata, 0);
1898 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1899 CU_ASSERT_NOT_EQUAL(result, 1);
1931 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1932 CU_ASSERT_NOT_EQUAL(result, 1);
1962 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1963 CU_ASSERT_NOT_EQUAL(result, 1);
1993 CU_ASSERT_EQUAL(rtn,
ES_NONE);
1994 CU_ASSERT_NOT_EQUAL(result, 1);
2024 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2025 CU_ASSERT_NOT_EQUAL(result, 1);
2032 CU_ASSERT(rast2 != NULL);
2037 CU_ASSERT(band2 != NULL);
2054 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2055 CU_ASSERT_NOT_EQUAL(result, 1);
2065 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2066 CU_ASSERT_NOT_EQUAL(result, 1);
2076 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2077 CU_ASSERT_NOT_EQUAL(result, 1);
2104 CU_ASSERT(rast1 != NULL);
2109 CU_ASSERT(band1 != NULL);
2117 CU_ASSERT_EQUAL(nodata, 0);
2124 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2125 CU_ASSERT_EQUAL(result, 1);
2139 CU_ASSERT(rast2 != NULL);
2143 CU_ASSERT(band2 != NULL);
2151 CU_ASSERT_EQUAL(nodata, 0);
2158 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2159 CU_ASSERT_NOT_EQUAL(result, 1);
2166 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2167 CU_ASSERT_NOT_EQUAL(result, 1);
2187 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2188 CU_ASSERT_NOT_EQUAL(result, 1);
2209 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2210 CU_ASSERT_NOT_EQUAL(result, 1);
2232 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2233 CU_ASSERT_NOT_EQUAL(result, 1);
2256 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2257 CU_ASSERT_NOT_EQUAL(result, 1);
2282 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2283 CU_ASSERT_NOT_EQUAL(result, 1);
2308 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2309 CU_ASSERT_NOT_EQUAL(result, 1);
2334 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2335 CU_ASSERT_NOT_EQUAL(result, 1);
2361 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2362 CU_ASSERT_EQUAL(result, 1);
2382 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2383 CU_ASSERT_EQUAL(result, 1);
2401 CU_ASSERT(rast2 != NULL);
2405 CU_ASSERT(band2 != NULL);
2418 CU_ASSERT_EQUAL(nodata, 0);
2425 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2426 CU_ASSERT_NOT_EQUAL(result, 1);
2458 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2459 CU_ASSERT_NOT_EQUAL(result, 1);
2489 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2490 CU_ASSERT_NOT_EQUAL(result, 1);
2520 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2521 CU_ASSERT_NOT_EQUAL(result, 1);
2551 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2552 CU_ASSERT_NOT_EQUAL(result, 1);
2559 CU_ASSERT(rast2 != NULL);
2564 CU_ASSERT(band2 != NULL);
2581 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2582 CU_ASSERT_NOT_EQUAL(result, 1);
2592 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2593 CU_ASSERT_NOT_EQUAL(result, 1);
2603 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2604 CU_ASSERT_NOT_EQUAL(result, 1);
2631 CU_ASSERT(rast1 != NULL);
2636 CU_ASSERT(band1 != NULL);
2644 CU_ASSERT_EQUAL(nodata, 0);
2651 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2652 CU_ASSERT_EQUAL(result, 1);
2666 CU_ASSERT(rast2 != NULL);
2670 CU_ASSERT(band2 != NULL);
2678 CU_ASSERT_EQUAL(nodata, 0);
2685 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2686 CU_ASSERT_NOT_EQUAL(result, 1);
2693 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2694 CU_ASSERT_NOT_EQUAL(result, 1);
2714 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2715 CU_ASSERT_NOT_EQUAL(result, 1);
2736 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2737 CU_ASSERT_NOT_EQUAL(result, 1);
2759 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2760 CU_ASSERT_NOT_EQUAL(result, 1);
2783 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2784 CU_ASSERT_NOT_EQUAL(result, 1);
2809 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2810 CU_ASSERT_NOT_EQUAL(result, 1);
2835 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2836 CU_ASSERT_NOT_EQUAL(result, 1);
2861 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2862 CU_ASSERT_NOT_EQUAL(result, 1);
2888 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2889 CU_ASSERT_EQUAL(result, 1);
2909 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2910 CU_ASSERT_EQUAL(result, 1);
2928 CU_ASSERT(rast2 != NULL);
2932 CU_ASSERT(band2 != NULL);
2945 CU_ASSERT_EQUAL(nodata, 0);
2952 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2953 CU_ASSERT_NOT_EQUAL(result, 1);
2985 CU_ASSERT_EQUAL(rtn,
ES_NONE);
2986 CU_ASSERT_NOT_EQUAL(result, 1);
3016 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3017 CU_ASSERT_NOT_EQUAL(result, 1);
3047 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3048 CU_ASSERT_NOT_EQUAL(result, 1);
3078 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3079 CU_ASSERT_NOT_EQUAL(result, 1);
3086 CU_ASSERT(rast2 != NULL);
3091 CU_ASSERT(band2 != NULL);
3108 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3109 CU_ASSERT_NOT_EQUAL(result, 1);
3119 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3120 CU_ASSERT_NOT_EQUAL(result, 1);
3130 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3131 CU_ASSERT_NOT_EQUAL(result, 1);
3158 CU_ASSERT(rast1 != NULL);
3163 CU_ASSERT(band1 != NULL);
3171 CU_ASSERT_EQUAL(nodata, 0);
3179 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3180 CU_ASSERT_EQUAL(result, 1);
3188 CU_ASSERT_NOT_EQUAL(rtn,
ES_NONE);
3202 CU_ASSERT(rast2 != NULL);
3206 CU_ASSERT(band2 != NULL);
3214 CU_ASSERT_EQUAL(nodata, 0);
3222 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3223 CU_ASSERT_EQUAL(result, 1);
3231 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3232 CU_ASSERT_EQUAL(result, 1);
3240 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3241 CU_ASSERT_EQUAL(result, 1);
3262 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3263 CU_ASSERT_EQUAL(result, 1);
3285 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3286 CU_ASSERT_EQUAL(result, 1);
3309 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3310 CU_ASSERT_EQUAL(result, 1);
3334 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3335 CU_ASSERT_NOT_EQUAL(result, 1);
3361 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3362 CU_ASSERT_NOT_EQUAL(result, 1);
3370 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3371 CU_ASSERT_EQUAL(result, 1);
3398 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3399 CU_ASSERT_EQUAL(result, 1);
3420 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3421 CU_ASSERT_EQUAL(result, 1);
3439 CU_ASSERT(rast2 != NULL);
3443 CU_ASSERT(band2 != NULL);
3456 CU_ASSERT_EQUAL(nodata, 0);
3464 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3465 CU_ASSERT_EQUAL(result, 1);
3498 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3499 CU_ASSERT_EQUAL(result, 1);
3530 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3531 CU_ASSERT_EQUAL(result, 1);
3562 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3563 CU_ASSERT_EQUAL(result, 1);
3594 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3595 CU_ASSERT_EQUAL(result, 1);
3628 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3629 CU_ASSERT_NOT_EQUAL(result, 1);
3637 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3638 CU_ASSERT_EQUAL(result, 1);
3645 CU_ASSERT(rast2 != NULL);
3650 CU_ASSERT(band2 != NULL);
3668 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3669 CU_ASSERT_EQUAL(result, 1);
3680 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3681 CU_ASSERT_EQUAL(result, 1);
3692 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3693 CU_ASSERT_EQUAL(result, 1);
3720 CU_ASSERT(rast1 != NULL);
3725 CU_ASSERT(band1 != NULL);
3733 CU_ASSERT_EQUAL(nodata, 0);
3741 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3742 CU_ASSERT_NOT_EQUAL(result, 1);
3750 CU_ASSERT_NOT_EQUAL(rtn,
ES_NONE);
3764 CU_ASSERT(rast2 != NULL);
3768 CU_ASSERT(band2 != NULL);
3776 CU_ASSERT_EQUAL(nodata, 0);
3784 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3785 CU_ASSERT_NOT_EQUAL(result, 1);
3793 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3794 CU_ASSERT_NOT_EQUAL(result, 1);
3802 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3803 CU_ASSERT_EQUAL(result, 1);
3824 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3825 CU_ASSERT_NOT_EQUAL(result, 1);
3847 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3848 CU_ASSERT_EQUAL(result, 1);
3871 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3872 CU_ASSERT_EQUAL(result, 1);
3896 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3897 CU_ASSERT_NOT_EQUAL(result, 1);
3923 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3924 CU_ASSERT_NOT_EQUAL(result, 1);
3932 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3933 CU_ASSERT_EQUAL(result, 1);
3960 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3961 CU_ASSERT_EQUAL(result, 1);
3982 CU_ASSERT_EQUAL(rtn,
ES_NONE);
3983 CU_ASSERT_NOT_EQUAL(result, 1);
4001 CU_ASSERT(rast2 != NULL);
4005 CU_ASSERT(band2 != NULL);
4018 CU_ASSERT_EQUAL(nodata, 0);
4026 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4027 CU_ASSERT_EQUAL(result, 1);
4060 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4061 CU_ASSERT_EQUAL(result, 1);
4092 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4093 CU_ASSERT_NOT_EQUAL(result, 1);
4124 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4125 CU_ASSERT_EQUAL(result, 1);
4156 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4157 CU_ASSERT_NOT_EQUAL(result, 1);
4190 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4191 CU_ASSERT_NOT_EQUAL(result, 1);
4199 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4200 CU_ASSERT_EQUAL(result, 1);
4207 CU_ASSERT(rast2 != NULL);
4212 CU_ASSERT(band2 != NULL);
4230 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4231 CU_ASSERT_EQUAL(result, 1);
4242 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4243 CU_ASSERT_EQUAL(result, 1);
4254 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4255 CU_ASSERT_EQUAL(result, 1);
4282 CU_ASSERT(rast1 != NULL);
4287 CU_ASSERT(band1 != NULL);
4295 CU_ASSERT_EQUAL(nodata, 0);
4309 CU_ASSERT(rast2 != NULL);
4313 CU_ASSERT(band2 != NULL);
4321 CU_ASSERT_EQUAL(nodata, 0);
4328 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4329 CU_ASSERT_EQUAL(result, 1);
4336 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4337 CU_ASSERT_EQUAL(result, 1);
4357 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4358 CU_ASSERT_EQUAL(result, 1);
4379 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4380 CU_ASSERT_EQUAL(result, 1);
4402 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4403 CU_ASSERT_EQUAL(result, 1);
4426 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4427 CU_ASSERT_NOT_EQUAL(result, 1);
4452 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4453 CU_ASSERT_NOT_EQUAL(result, 1);
4479 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4480 CU_ASSERT_EQUAL(result, 1);
4500 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4501 CU_ASSERT_EQUAL(result, 1);
4519 CU_ASSERT(rast2 != NULL);
4523 CU_ASSERT(band2 != NULL);
4536 CU_ASSERT_EQUAL(nodata, 0);
4543 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4544 CU_ASSERT_EQUAL(result, 1);
4576 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4577 CU_ASSERT_EQUAL(result, 1);
4607 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4608 CU_ASSERT_EQUAL(result, 1);
4638 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4639 CU_ASSERT_EQUAL(result, 1);
4669 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4670 CU_ASSERT_EQUAL(result, 1);
4677 CU_ASSERT(rast2 != NULL);
4682 CU_ASSERT(band2 != NULL);
4699 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4700 CU_ASSERT_EQUAL(result, 1);
4710 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4711 CU_ASSERT_EQUAL(result, 1);
4721 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4722 CU_ASSERT_EQUAL(result, 1);
4736 CU_ASSERT(rast1 != NULL);
4740 CU_ASSERT(rast2 != NULL);
4744 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4745 CU_ASSERT_NOT_EQUAL(aligned, 0);
4749 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4750 CU_ASSERT_EQUAL(aligned, 0);
4751 CU_ASSERT_STRING_EQUAL(reason,
"The rasters have different scales on the X axis");
4756 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4757 CU_ASSERT_EQUAL(aligned, 0);
4758 CU_ASSERT_STRING_EQUAL(reason,
"The rasters have different skews on the X axis");
4763 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4764 CU_ASSERT_NOT_EQUAL(aligned, 0);
4768 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4769 CU_ASSERT_NOT_EQUAL(aligned, 0);
4773 CU_ASSERT_EQUAL(rtn,
ES_NONE);
4774 CU_ASSERT_EQUAL(aligned, 0);
4775 CU_ASSERT_STRING_EQUAL(reason,
"The rasters (pixel corner coordinates) are not aligned");
4785 CU_pSuite suite = CU_add_suite(
"spatial_relationship", NULL, NULL);
static void test_raster_same_alignment()
static void test_raster_geos_overlaps()
static void test_raster_geos_covered_by()
static void test_raster_within_distance()
static void test_raster_fully_within_distance()
static void test_raster_geos_touches()
static void test_raster_geos_covers()
static void test_raster_geos_contains()
static void test_raster_intersects()
void spatial_relationship_suite_setup(void)
static void test_raster_geos_contains_properly()
#define PG_ADD_TEST(suite, testfunc)
rt_errorstate rt_raster_contains(rt_raster rast1, int nband1, rt_raster rast2, int nband2, int *contains)
Return ES_ERROR if error occurred in function.
rt_errorstate rt_raster_fully_within_distance(rt_raster rast1, int nband1, rt_raster rast2, int nband2, double distance, int *dfwithin)
Return ES_ERROR if error occurred in function.
rt_errorstate rt_raster_contains_properly(rt_raster rast1, int nband1, rt_raster rast2, int nband2, int *contains)
Return ES_ERROR if error occurred in function.
void rt_raster_set_scale(rt_raster raster, double scaleX, double scaleY)
Set scale in projection units.
void rt_raster_set_skews(rt_raster raster, double skewX, double skewY)
Set skews about the X and Y axis.
rt_raster rt_raster_new(uint32_t width, uint32_t height)
Construct a raster with given dimensions.
rt_errorstate rt_raster_intersects(rt_raster rast1, int nband1, rt_raster rast2, int nband2, int *intersects)
Return ES_ERROR if error occurred in function.
rt_errorstate rt_raster_coveredby(rt_raster rast1, int nband1, rt_raster rast2, int nband2, int *coveredby)
Return ES_ERROR if error occurred in function.
rt_errorstate rt_raster_touches(rt_raster rast1, int nband1, rt_raster rast2, int nband2, int *touches)
Return ES_ERROR if error occurred in function.
rt_errorstate rt_band_set_nodata(rt_band band, double val, int *converted)
Set nodata value.
rt_errorstate rt_band_set_pixel(rt_band band, int x, int y, double val, int *converted)
Set single pixel's value.
rt_errorstate rt_raster_overlaps(rt_raster rast1, int nband1, rt_raster rast2, int nband2, int *overlaps)
Return ES_ERROR if error occurred in function.
rt_errorstate rt_band_get_nodata(rt_band band, double *nodata)
Get NODATA value.
rt_errorstate rt_raster_within_distance(rt_raster rast1, int nband1, rt_raster rast2, int nband2, double distance, int *dwithin)
Return ES_ERROR if error occurred in function.
rt_errorstate rt_raster_same_alignment(rt_raster rast1, rt_raster rast2, int *aligned, char **reason)
rt_errorstate rt_raster_covers(rt_raster rast1, int nband1, rt_raster rast2, int nband2, int *covers)
Return ES_ERROR if error occurred in function.
void rt_raster_set_offsets(rt_raster raster, double x, double y)
Set insertion points in projection units.
rt_band cu_add_band(rt_raster raster, rt_pixtype pixtype, int hasnodata, double nodataval)
void cu_free_raster(rt_raster raster)