DIPlib Documentation - ©1995-2015 Quantitative Imaging Group, Delft University of Technology.

# AttenuationCorrection

Attenuation correction algorithm

## SYNOPSIS

`#include "dip_microscopy.h"`

dip_Error dip_AttenuationCorrection ( in, out, fAttenuation, bAttenuation, background, threshold, NA, refIndex, ratio, method )

## DATA TYPES

binary, integer, float

## FUNCTION

This function implements an attenuation correction using three different recursive attenuation correction algorithms. The RAC-DET algorithm is the most accurate one, since it takes both forward and backward attenuation into account. It is however considerably slower that the RAC-LT2 and RAC-LT1 algorithms which take only forward attenuation into account. These last two algorithms assume a constant attenuation (`background`) for pixels with an intensity lower than the `threshold`.

## ARGUMENTS

Data type | Name | Description
`dip_Image` | `in` | Input image
`dip_Image` | `out` | Output image
`dip_float` | `fAttenuation` | Forward attenuation factor
`dip_float` | `bAttenuation` | Backward attenuation factor
`dip_float` | `background` | Background attenuation factor
`dip_float` | `threshold` | Background threshold
`dip_float` | `NA` | Numerical aperture
`dip_float` | `refIndex` | Refractive index
`dip_float` | `ratio` | Z/X sampling ratio
`dipf_AttenuationCorrection` | `method` | Correction method

The `dipf_AttenuationCorrection` enumaration consists of the following flags:

Name | Description
`DIP_ATTENUATION_RAC_LT2` | Recursive Attenuation Correction algorithm using two Light Cone convolutions
`DIP_ATTENUATION_RAC_LT1` | Recursive Attenuation Correction algorithm using one Light Cone convolution
`DIP_ATTENUATION_RAC_DET` | Recursive Attenuation Correction algorithm using Directional Extinction Tracking

## LITERATURE

K.C. Strasters, H.T.M. van der Voort, J.M. Geusebroek, and A.W.M. Smeulders, Fast attenuation correction in fluorescence confocal imaging: a recursive approach, BioImaging, vol. 2, no. 2, 1994, 78-92.

## AUTHOR

Karel Strasters, adapted to DIPlib by Geert van Kempen.

## SEE ALSO

`SimulatedAttenuation`, `ExponentialFitCorrection`