use na::{Real, DefaultAllocator}; use traits::{Dimension, Alloc}; use aliases::Vec; /// The dot product of the normalized version of `x` and `y`. pub fn fast_normalize_dot(x: &Vec, y: &Vec) -> N where DefaultAllocator: Alloc { // XXX: improve those. x.normalize().dot(&y.normalize()) } /// The dot product of the normalized version of `x` and `y`. pub fn normalize_dot(x: &Vec, y: &Vec) -> N where DefaultAllocator: Alloc { // XXX: improve those. x.normalize().dot(&y.normalize()) }