Function lyon_core::math_utils::compute_normal
[−]
[src]
pub fn compute_normal(e1: Vec2, e2: Vec2) -> Vec2
Compute a normal vector at a point P such that x ---e1----> P ---e2---> x
The resulting vector is not normalized. The length is such that extruding the shape would yield parallel segments exactly 1 unit away from their original. (useful for generating strokes and vertex-aa). The normal points towards the left side of e1.