PhotoCraft: An open-source, photo editor written by scratch in pure Rust
GPU parity: a bevel gloss contour that starts at 100 % (#7360)
Hector Villarreal46d48523a7f2
diff --git a/crates/gpu/tests/parity.rs b/crates/gpu/tests/parity.rsindex 84d3d0e93..f6fed2994 100644--- a/crates/gpu/tests/parity.rs+++ b/crates/gpu/tests/parity.rs@@ -1386,6 +1386,14 @@ fn effect_cases() -> Vec<(&'static str, Vec<Effect>)> {let mut bevel_contour = bevel(BevelStyle::InnerBevel, true, 8.0, 3.0);bevel_contour.gloss_contour = contour();bevel_contour.use_global_light = false;+ // #7360: a gloss contour that starts at 100 % (Rolling Slope - Descending), as on the type in+ // the report; its flat face and slopes take the contour-mapped shading on both renderers.+ let mut bevel_gloss_high = bevel(BevelStyle::InnerBevel, true, 8.0, 2.0);+ bevel_gloss_high.gloss_contour = Contour::Custom {+ name: "descending".into(),+ points: vec![Cp { input: 0.0, output: 1.0 }, Cp { input: 0.4, output: 0.4 }, Cp { input: 1.0, output: 0.0 }],+ corners: vec![],+ };vec![("drop shadow", vec![Effect::DropShadow(shadow(BlendMode::Multiply, 0.75, 120.0, 6.0, 8.0, 0.0))]),("drop shadow spread contour", vec![Effect::DropShadow(ds_contour)]),@@ -1452,6 +1460,7 @@ fn effect_cases() -> Vec<(&'static str, Vec<Effect>)> {})],),("bevel contour own light", vec![Effect::BevelEmboss(bevel_contour)]),+ ("bevel gloss starting high", vec![Effect::BevelEmboss(bevel_gloss_high)]),("satin", vec![Effect::Satin(satin)]),("satin inverted contour", vec![Effect::Satin(satin_inv)]),("stroke outside colour", vec![Effect::Stroke(stroke(4.0, StrokePosition::Outside, FxPaint::Color(Color::rgb(0.95, 0.85, 0.1))))]),