Skip to content

Commit d2d27a6

Browse files
committed
shaders: remove explicit fn pointer
1 parent 78827ee commit d2d27a6

File tree

1 file changed

+1
-1
lines changed
  • node-graph/gcore-shaders/src/color

1 file changed

+1
-1
lines changed

node-graph/gcore-shaders/src/color/color.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -701,7 +701,7 @@ impl Color {
701701
if c_s <= 0.5 {
702702
c_b - (1. - 2. * c_s) * c_b * (1. - c_b)
703703
} else {
704-
let d: fn(f32) -> f32 = |x| if x <= 0.25 { ((16. * x - 12.) * x + 4.) * x } else { x.sqrt() };
704+
let d = |x: f32| if x <= 0.25 { ((16. * x - 12.) * x + 4.) * x } else { x.sqrt() };
705705
c_b + (2. * c_s - 1.) * (d(c_b) - c_b)
706706
}
707707
}

0 commit comments

Comments
 (0)