Construct an rt_raster from a text HEXWKB representation.
412 assert(NULL != hexwkb);
417 if (hexwkbsize % 2) {
418 rterror(
"rt_raster_from_hexwkb: Raster HEXWKB input must have an even number of characters");
421 wkbsize = hexwkbsize / 2;
425 rterror(
"rt_raster_from_hexwkb: Out of memory allocating memory for decoding HEXWKB");
430 for (i = 0; i < wkbsize; ++i) {
431 wkb[i] =
parse_hex((
char*) & (hexwkb[i * 2]));
void rterror(const char *fmt,...)
Wrappers used for reporting errors and info.
void * rtalloc(size_t size)
Wrappers used for managing memory.
#define RASTER_DEBUGF(level, msg,...)
uint8_t parse_hex(char *str)
Convert a single hex digit into the corresponding char.
rt_raster rt_raster_from_wkb(const uint8_t *wkb, uint32_t wkbsize)
Construct an rt_raster from a binary WKB representation.
void rtdealloc(void *mem)