Function vec2::norm_mut [−][src]
pub fn norm_mut<'out, T>(out: &'out mut [T; 2]) -> T where
T: Real,
&'a T: Mul<&'b T, Output = T> + Div<&'b T, Output = T>,
Example
let mut v = vec2::new_one::<f32>(); assert_eq!(vec2::norm_mut(&mut v), 2_f32.sqrt()); assert_eq!(v, [1_f32 / 2_f32.sqrt(); 2]);