make rtengine::processImage return an Imagefloat instead of an Image16

This is for supporting saving to 32-bit float TIFFs
This commit is contained in:
Alberto Griggio
2017-11-20 00:10:51 +01:00
parent d47e7f67b2
commit bc8b8902e6
15 changed files with 157 additions and 96 deletions

View File

@@ -46,7 +46,7 @@ static inline float Lanc (float x, float a)
}
}
void ImProcFunctions::Lanczos (const Image16* src, Image16* dst, float scale)
void ImProcFunctions::Lanczos (const Imagefloat* src, Imagefloat* dst, float scale)
{
const float delta = 1.0f / scale;
@@ -159,9 +159,9 @@ void ImProcFunctions::Lanczos (const Image16* src, Image16* dst, float scale)
b += wh[k] * lb[jj];
}
dst->r (i, j) = CLIP (static_cast<int> (r));
dst->g (i, j) = CLIP (static_cast<int> (g));
dst->b (i, j) = CLIP (static_cast<int> (b));
dst->r (i, j) = CLIP (r);//static_cast<int> (r));
dst->g (i, j) = CLIP (g);//static_cast<int> (g));
dst->b (i, j) = CLIP (b);//static_cast<int> (b));
}
}
@@ -396,7 +396,7 @@ float ImProcFunctions::resizeScale (const ProcParams* params, int fw, int fh, in
return (float)dScale;
}
void ImProcFunctions::resize (Image16* src, Image16* dst, float dScale)
void ImProcFunctions::resize (Imagefloat* src, Imagefloat* dst, float dScale)
{
#ifdef PROFILE
time_t t1 = clock();