Skip to main content

coverage

Function coverage 

Source
pub fn coverage(img: &CaptureImage, bg: [u8; 4], eps: u8) -> f32
Expand description

Fraction of pixels whose RGB differs from bg by more than eps on any channel — “how much of the frame is lit” (0.0..=1.0). Alpha is ignored.