Ansel 0.0
A darktable fork - bloat + design vision
Loading...
Searching...
No Matches
detail.c File Reference
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define FAST_BLUR_5
 
#define FAST_BLUR_9
 

Functions

void dt_masks_extend_border (float *const restrict mask, const int width, const int height, const int border)
 
void _masks_blur_5x5_coeff (float *c, const float sigma)
 
void dt_masks_blur_9x9_coeff (float *c, const float sigma)
 
void dt_masks_blur_9x9 (float *const restrict src, float *const restrict out, const int width, const int height, const float sigma)
 
void _masks_blur_13x13_coeff (float *c, const float sigma)
 
void dt_masks_calc_rawdetail_mask (float *const restrict src, float *const restrict mask, float *const restrict tmp, const int width, const int height, const dt_aligned_pixel_t wb)
 
static float calcBlendFactor (float val, float threshold)
 
void dt_masks_calc_detail_mask (float *const restrict src, float *const restrict out, float *const restrict tmp, const int width, const int height, const float threshold, const gboolean detail)
 

Macro Definition Documentation

◆ FAST_BLUR_5

#define FAST_BLUR_5
Value:
( \
blurmat[0] * ((src[i - w2 - 1] + src[i - w2 + 1]) + (src[i - w1 - 2] + src[i - w1 + 2]) + (src[i + w1 - 2] + src[i + w1 + 2]) + (src[i + w2 - 1] + src[i + w2 + 1])) + \
blurmat[1] * (src[i - w2] + src[i - 2] + src[i + 2] + src[i + w2]) + \
blurmat[2] * (src[i - w1 - 1] + src[i - w1 + 1] + src[i + w1 - 1] + src[i + w1 + 1]) + \
blurmat[3] * (src[i - w1] + src[i - 1] + src[i + 1] + src[i + w1]) + \
blurmat[4] * src[i] )
#define w2
Definition lmmse.c:61
#define w1
Definition lmmse.c:60

◆ FAST_BLUR_9

#define FAST_BLUR_9
Value:
( \
blurmat[12] * (src[i - w4 - 2] + src[i - w4 + 2] + src[i - w2 - 4] + src[i - w2 + 4] + src[i + w2 - 4] + src[i + w2 + 4] + src[i + w4 - 2] + src[i + w4 + 2]) + \
blurmat[11] * (src[i - w4 - 1] + src[i - w4 + 1] + src[i - w1 - 4] + src[i - w1 + 4] + src[i + w1 - 4] + src[i + w1 + 4] + src[i + w4 - 1] + src[i + w4 + 1]) + \
blurmat[10] * (src[i - w4] + src[i - 4] + src[i + 4] + src[i + w4]) + \
blurmat[9] * (src[i - w3 - 3] + src[i - w3 + 3] + src[i + w3 - 3] + src[i + w3 + 3]) + \
blurmat[8] * (src[i - w3 - 2] + src[i - w3 + 2] + src[i - w2 - 3] + src[i - w2 + 3] + src[i + w2 - 3] + src[i + w2 + 3] + src[i + w3 - 2] + src[i + w3 + 2]) + \
blurmat[7] * (src[i - w3 - 1] + src[i - w3 + 1] + src[i - w1 - 3] + src[i - w1 + 3] + src[i + w1 - 3] + src[i + w1 + 3] + src[i + w3 - 1] + src[i + w3 + 1]) + \
blurmat[6] * (src[i - w3] + src[i - 3] + src[i + 3] + src[i + w3]) + \
blurmat[5] * (src[i - w2 - 2] + src[i - w2 + 2] + src[i + w2 - 2] + src[i + w2 + 2]) + \
blurmat[4] * (src[i - w2 - 1] + src[i - w2 + 1] + src[i - w1 - 2] + src[i - w1 + 2] + src[i + w1 - 2] + src[i + w1 + 2] + src[i + w2 - 1] + src[i + w2 + 1]) + \
blurmat[3] * (src[i - w2] + src[i - 2] + src[i + 2] + src[i + w2]) + \
blurmat[2] * (src[i - w1 - 1] + src[i - w1 + 1] + src[i + w1 - 1] + src[i + w1 + 1]) + \
blurmat[1] * (src[i - w1] + src[i - 1] + src[i + 1] + src[i + w1]) + \
blurmat[0] * src[i] )
#define w4
Definition lmmse.c:63
#define w3
Definition lmmse.c:62

Function Documentation

◆ _masks_blur_13x13_coeff()

void _masks_blur_13x13_coeff ( float *  c,
const float  sigma 
)

References kernel(), and sqf().

◆ _masks_blur_5x5_coeff()

void _masks_blur_5x5_coeff ( float *  c,
const float  sigma 
)

References kernel(), and sqf().

◆ calcBlendFactor()

static float calcBlendFactor ( float  val,
float  threshold 
)
inlinestatic

References dt_fast_expf().

Referenced by dt_masks_calc_detail_mask().

◆ dt_masks_blur_9x9()

void dt_masks_blur_9x9 ( float *const restrict  src,
float *const restrict  out,
const int  width,
const int  height,
const float  sigma 
)

◆ dt_masks_blur_9x9_coeff()

void dt_masks_blur_9x9_coeff ( float *  c,
const float  sigma 
)

References kernel(), and sqf().

Referenced by dt_masks_blur_9x9().

◆ dt_masks_calc_detail_mask()

void dt_masks_calc_detail_mask ( float *const restrict  src,
float *const restrict  out,
float *const restrict  tmp,
const int  width,
const int  height,
const float  threshold,
const gboolean  detail 
)

◆ dt_masks_calc_rawdetail_mask()

void dt_masks_calc_rawdetail_mask ( float *const restrict  src,
float *const restrict  mask,
float *const restrict  tmp,
const int  width,
const int  height,
const dt_aligned_pixel_t  wb 
)

◆ dt_masks_extend_border()

void dt_masks_extend_border ( float *const restrict  mask,
const int  width,
const int  height,
const int  border 
)

References height, MAX, MIN, and width.

Referenced by dt_masks_blur_9x9(), and dt_masks_calc_rawdetail_mask().