|
1 | 1 | /* |
2 | 2 | This file is part of darktable, |
3 | | - Copyright (C) 2016-2024 darktable developers. |
| 3 | + Copyright (C) 2016-2025 darktable developers. |
4 | 4 |
|
5 | 5 | darktable is free software: you can redistribute it and/or modify |
6 | 6 | it under the terms of the GNU General Public License as published by |
@@ -448,34 +448,6 @@ void dt_iop_image_mul_const(float *const buf, |
448 | 448 | buf[k] *= mul_value; |
449 | 449 | } |
450 | 450 |
|
451 | | -void dt_iop_image_div_const(float *const buf, |
452 | | - const float div_value, |
453 | | - const size_t width, |
454 | | - const size_t height, |
455 | | - const size_t ch) |
456 | | -{ |
457 | | - const size_t nfloats = width * height * ch; |
458 | | -#ifdef _OPENMP |
459 | | - if(nfloats > parallel_imgop_minimum) // is the copy big enough to outweigh threading overhead? |
460 | | - { |
461 | | - // we can gain a little by using a small number of threads in |
462 | | - // parallel, but not much since the memory bus quickly saturates |
463 | | - // (basically, each core can saturate a memory channel, so a |
464 | | - // system with quad-channel memory won't be able to take advantage |
465 | | - // of more than four cores). |
466 | | - const int nthreads = MIN(darktable.num_openmp_threads,parallel_imgop_maxthreads); |
467 | | - DT_OMP_FOR_SIMD(num_threads(nthreads) aligned(buf:16)) |
468 | | - for(size_t k = 0; k < nfloats; k++) |
469 | | - buf[k] /= div_value; |
470 | | - return; |
471 | | - } |
472 | | -#endif // _OPENMP |
473 | | - // no OpenMP, or image too small to bother parallelizing |
474 | | - DT_OMP_SIMD(aligned(buf:16)) |
475 | | - for(size_t k = 0; k < nfloats; k++) |
476 | | - buf[k] /= div_value; |
477 | | -} |
478 | | - |
479 | 451 | // elementwise: buf = lammda*buf + (1-lambda)*other |
480 | 452 | void dt_iop_image_linear_blend(float *const restrict buf, |
481 | 453 | const float lambda, |
|
0 commit comments