382 CU_ASSERT(rast != NULL);
388 CU_ASSERT(band != NULL);
390 for (y = 0; y < maxY; y++) {
391 for (x = 0; x < maxX; x++) {
398 CU_ASSERT(geom != NULL);
400 CU_ASSERT_STRING_EQUAL(wkt,
"POLYGON((0 0,5 0,5 -5,0 -5,0 0))");
414 CU_ASSERT(geom != NULL);
416 CU_ASSERT_STRING_EQUAL(wkt,
"POLYGON((0 -1,5 -1,5 -5,0 -5,0 -1))");
430 CU_ASSERT(geom != NULL);
432 CU_ASSERT_STRING_EQUAL(wkt,
"POLYGON((0 -1,4 -1,4 -5,0 -5,0 -1))");
446 CU_ASSERT(geom != NULL);
448 CU_ASSERT_STRING_EQUAL(wkt,
"POLYGON((0 -1,4 -1,4 -4,0 -4,0 -1))");
462 CU_ASSERT(geom != NULL);
464 CU_ASSERT_STRING_EQUAL(wkt,
"POLYGON((1 -1,4 -1,4 -4,1 -4,1 -1))");
483 CU_ASSERT(geom != NULL);
485 CU_ASSERT_STRING_EQUAL(wkt,
"POLYGON((2 -1,3 -1,3 -4,2 -4,2 -1))");
496 CU_ASSERT(geom != NULL);
498 CU_ASSERT_STRING_EQUAL(wkt,
"POLYGON((2 -2,3 -2,3 -3,2 -3,2 -2))");
505 CU_ASSERT(band != NULL);
507 for (y = 0; y < maxY; y++) {
508 for (x = 0; x < maxX; x++) {
515 CU_ASSERT(geom != NULL);
517 CU_ASSERT_STRING_EQUAL(wkt,
"POLYGON((0 0,5 0,5 -5,0 -5,0 0))");
void lwgeom_free(LWGEOM *geom)
void cu_free_raster(rt_raster raster)
rt_band cu_add_band(rt_raster raster, rt_pixtype pixtype, int hasnodata, double nodataval)
void rt_raster_set_scale(rt_raster raster, double scaleX, double scaleY)
Set scale in projection units.
void rt_raster_set_offsets(rt_raster raster, double x, double y)
Set insertion points in projection units.
rt_raster rt_raster_new(uint32_t width, uint32_t height)
Construct a raster with given dimensions.
void rtdealloc(void *mem)
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_get_perimeter(rt_raster raster, int nband, LWGEOM **perimeter)
Get raster perimeter.
static char * lwgeom_to_text(const LWGEOM *lwgeom)