gbc | R Documentation |
Gamma back correction of JPEG images
gbc(DN_from_JPEG, gamma = 2.2)
DN_from_JPEG |
Numeric vector or object of the SpatRaster class. Digital numbers from a JPEG file (0 to 255, i.e., the standard 8-bit encoded). |
gamma |
Numeric vector of length one. Gamma value. Please see \insertCiteDiaz2018;textualrcaiman for details. |
Digital cameras usually use sRGB as color space. It is a standard developed to ensure accurate color and tone management. The transfer function of sRGB, known as gamma correction, is very close to a power function with the exponent 1/2.2. This is why a DN of a born-digital photograph that was encoded in sRGB has a non-linear relationship with luminance despite having the sensor a linear response.
The same class as DN_from_JPEG
, with dimension unchanged but values
rescaled between 0
and 1
in a non-linear fashion.
Other Pre-processing Functions:
enhance_caim()
,
local_fuzzy_thresholding()
,
membership_to_color()
,
normalize()
path <- system.file("external/DSCN4500.JPG", package = "rcaiman")
r <- read_caim(path, c(1250, 1020) - 745, 745 * 2, 745 * 2)
r
gbc(r)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.