make white output more likely in float mask

This commit is contained in:
kageru 2020-02-19 20:24:08 +01:00
parent ecab0b5028
commit d9bc767c26
Signed by: kageru
GPG Key ID: 8282A2BEA4ADA3D2

View File

@ -31,12 +31,12 @@ fn get_mask_value(x: f32, y: f32, luma_scaling: f32) -> f32 {
}
macro_rules! from_property {
($prop: expr) => (
($prop: expr) => {
match $prop {
Property::Constant(p) => p,
Property::Variable => unreachable!(),
}
)
};
}
macro_rules! int_filter {
@ -81,7 +81,7 @@ fn filter_for_float(frame: &mut FrameRefMut, src_frame: FrameRef, average: f32,
.zip(src_frame.plane_row::<f32>(0, row).iter())
{
unsafe {
ptr::write(pixel, lut[(src_pixel * 255f32) as usize]);
ptr::write(pixel, lut[(src_pixel * 255.99f32) as usize]);
}
}
}