}
}
- if (fabs(state->precision)>7)
+ if (abs(state->precision)>7)
lwerror("precision cannot be more than 7");
twkb = lwgeom_agg_to_twkb(&lwgeom_arrays, state->variant , &twkb_size,(int8_t) state->precision);
if ( (PG_NARGS()>1) && (!PG_ARGISNULL(1)) )
{
prec = PG_GETARG_INT32(1);
- if (fabs(prec)>7)
+ if (abs(prec)>7)
lwerror("precision cannot be more than 7");
}
else
VRTAddSimpleSource(
hbandDst, GDALGetRasterBand(hdsSrc, band->data.offline.bandNum + 1),
- abs(offset[0]), abs(offset[1]),
+ fabs(offset[0]), fabs(offset[1]),
band->width, band->height,
0, 0,
band->width, band->height,
(FLT_NEQ(*width, 0.0)) &&
(FLT_NEQ(*height, 0.0))
) {
- _dim[0] = fabs(*width);
- _dim[1] = fabs(*height);
+ _dim[0] = abs(*width);
+ _dim[1] = abs(*height);
if (FLT_NEQ(extent.MaxX, extent.MinX))
_scale[0] = fabs((extent.MaxX - extent.MinX) / _dim[0]);
(wkbtype == wkbLineString) ||
(wkbtype == wkbMultiLineString)
) &&
- FLT_EQ(_dim[0], 0) &&
- FLT_EQ(_dim[1], 0)
+ _dim[0] == 0 &&
+ _dim[1] == 0
) {
int result;
LWPOLY *epoly = NULL;
RASTER_DEBUGF(3, "Raster dimensions (width x height): %d x %d",
_dim[0], _dim[1]);
- if (FLT_EQ(_dim[0], 0) || FLT_EQ(_dim[1], 0)) {
- rterror("rt_raster_gdal_warp: The width (%f) or height (%f) of the warped raster is zero", _dim[0], _dim[1]);
+ if ( _dim[0] == 0 || _dim[1] == 0 ) {
+ rterror("rt_raster_gdal_warp: The width (%d) or height (%d) of the warped raster is zero", _dim[0], _dim[1]);
_rti_warp_arg_destroy(arg);
return NULL;
}