ahem, of-by-one error ?

This commit is contained in:
Tonton Th 2019-09-09 17:24:31 +02:00
parent 2f3a8870c4
commit ec56f998c2

View File

@ -10,6 +10,12 @@
int verbosity;
/* ---------------------------------------------------------------- */
static int gray_interpolate(FloatImg *s1, FloatImg *s2, FloatImg *d, float coef)
{
return -1;
}
/* ---------------------------------------------------------------- */
int fimg_interpolate(FloatImg *s1, FloatImg *s2, FloatImg *d, float coef)
{
int picsize, idx;
@ -31,7 +37,7 @@ if (FIMG_TYPE_RGB != d->type) {
return -9;
}
picsize = d->width * d->height * 2;
picsize = d->width * d->height * 3;
for (idx=0; idx<picsize; idx++) {
@ -39,6 +45,6 @@ for (idx=0; idx<picsize; idx++) {
}
return -1;
return 0;
}
/* ---------------------------------------------------------------- */