Skip to main content

Module color

Module color 

Source
Expand description

Color processing primitives.

This module provides functions for color correction in the raw processing pipeline:

  • White balance correction
  • Color matrix application (camera RGB to sRGB)
  • Gamma correction

All functions operate on 16-bit RGB data in the range [0, 65535].

Structs§

GammaLut
Pre-computed gamma correction lookup table.

Functions§

apply_color_matrix
Apply a 3x3 color matrix to an RGB image.
apply_gamma
Apply gamma correction to an RGB image.
apply_white_balance
Apply white balance to an RGB image.
apply_white_balance_raw
Apply white balance to a raw Bayer CFA image.
clamp_u16
Clamp a floating-point value to the u16 range [0, 65535].