pub fn normalize_with_constant(constant: f32, a: f32, b: f32) -> (f32, f32, f32)
Expand description

Normalizes a 3-vector with one value that stays constant. e.g. (0.6, 0.4, 0.8) => (0.6, 0.2, 0.4) Only tested with all-positive vectors, may misbehave when negatives are involved.