555{
558 int bandindex = 0;
559 bool hasnoband =
FALSE;
560
561
562 if (PG_ARGISNULL(0)) PG_RETURN_NULL();
564
566 if ( ! raster )
567 {
568 ereport(ERROR,
569 (errcode(ERRCODE_OUT_OF_MEMORY),
570 errmsg("RASTER_hasNoBand: Could not deserialize raster")));
571 PG_FREE_IF_COPY(pgraster, 0);
572 PG_RETURN_NULL();
573 }
574
575
576 bandindex = PG_GETARG_INT32(1);
578
580 PG_FREE_IF_COPY(pgraster, 0);
581
582 PG_RETURN_BOOL(hasnoband);
583}
void rt_raster_destroy(rt_raster raster)
Release memory associated to a raster.
int rt_raster_has_band(rt_raster raster, int nband)
Return TRUE if the raster has a band of this number.
rt_raster rt_raster_deserialize(void *serialized, int header_only)
Return a raster from a serialized form.
raster
Be careful!! Zeros function's input parameter can be a (height x width) array, not (width x height): ...