Definition at line 625 of file rt_util.c.
References FLT_NEQ, PT_16BSI, PT_16BUI, PT_1BB, PT_2BUI, PT_32BF, PT_32BSI, PT_32BUI, PT_4BUI, PT_64BF, PT_8BSI, PT_8BUI, PT_END, rt_pixtype_name(), and rtwarn().
Referenced by rt_band_reclass(), rt_band_set_nodata(), rt_band_set_pixel(), and rt_raster_generate_new_band().
642 if (fabs(checkvalint - initialvalue) >= 1) {
643 #if POSTGIS_RASTER_WARN_ON_TRUNCATION > 0 644 rtwarn(
"Value set for %s band got clamped from %f to %d",
646 initialvalue, checkvalint
651 else if (
FLT_NEQ(checkvalint, initialvalue)) {
652 #if POSTGIS_RASTER_WARN_ON_TRUNCATION > 0 653 rtwarn(
"Value set for %s band got truncated from %f to %d",
655 initialvalue, checkvalint
663 if (fabs(checkvaluint - initialvalue) >= 1) {
664 #if POSTGIS_RASTER_WARN_ON_TRUNCATION > 0 665 rtwarn(
"Value set for %s band got clamped from %f to %u",
667 initialvalue, checkvaluint
672 else if (
FLT_NEQ(checkvaluint, initialvalue)) {
673 #if POSTGIS_RASTER_WARN_ON_TRUNCATION > 0 674 rtwarn(
"Value set for %s band got truncated from %f to %u",
676 initialvalue, checkvaluint
688 if (
FLT_NEQ(checkvalfloat, initialvalue)) {
689 #if POSTGIS_RASTER_WARN_ON_TRUNCATION > 0 690 rtwarn(
"Value set for %s band got converted from %f to %f",
692 initialvalue, checkvalfloat
700 if (
FLT_NEQ(checkvaldouble, initialvalue)) {
701 #if POSTGIS_RASTER_WARN_ON_TRUNCATION > 0 702 rtwarn(
"Value set for %s band got converted from %f to %f",
704 initialvalue, checkvaldouble
void rtwarn(const char *fmt,...)
const char * rt_pixtype_name(rt_pixtype pixtype)