implement blur

This commit is contained in:
Vinzenz Schroeter 2025-02-28 11:58:04 +01:00
parent 1de6caa8a7
commit ea7262f8f5
2 changed files with 47 additions and 13 deletions

View file

@ -29,10 +29,11 @@ pub fn stream_window(connection: &Connection, options: StreamScreenOptions) {
loop {
let mut frame = get_next_frame(&capturer);
LedwandDither::histogram_correction(&mut frame);
let cutoff = if options.no_dither {
LedwandDither::median_brightness(&frame)
} else {
LedwandDither::histogram_correction(&mut frame);
LedwandDither::blur(&frame.clone(), &mut frame);
dither(&mut frame, &BiLevel);
u8::MAX / 2
};