Capture sharpening: some cleanups

This commit is contained in:
Ingo Weyrich
2020-01-15 22:15:31 +01:00
parent 88808d1364
commit 906347ab2d
2 changed files with 19 additions and 33 deletions

View File

@@ -188,6 +188,16 @@ public:
}
}
void fill(const T val, bool multiThread = false)
{
#ifdef _OPENMP
#pragma omp parallel for if(multiThread)
#endif
for (int i = 0; i < x * y; ++i) {
data[i] = val;
}
}
void free()
{
if ((owner) && (data)) {