PostGIS 3.7.0dev-r@@SVN_REVISION@@
Loading...
Searching...
No Matches

◆ rt_band_set_hasnodata_flag()

void rt_band_set_hasnodata_flag ( rt_band  band,
int  flag 
)

Set hasnodata flag value.

Parameters
band: the band on which to set the hasnodata flag
flag: the new hasnodata flag value. Must be 1 or 0.

Definition at line 840 of file rt_band.c.

840 {
841
842 assert(NULL != band);
843
844 band->hasnodata = (flag) ? 1 : 0;
845
846 /* isnodata depends on hasnodata */
847 if (!band->hasnodata && band->isnodata) {
848 RASTER_DEBUG(3, "Setting isnodata to FALSE as band no longer has NODATA");
849 band->isnodata = 0;
850 }
851}
#define RASTER_DEBUG(level, msg)
Definition librtcore.h:304

References RASTER_DEBUG.

Referenced by RASTER_setBandNoDataValue(), and test_band_metadata().

Here is the caller graph for this function: