rust/integral-geometry/src/lib.rs
changeset 14146 477faa7b8a48
parent 14145 3078123e84ea
child 14147 11202097584f
equal deleted inserted replaced
14145:3078123e84ea 14146:477faa7b8a48
    81     pub fn line_to(self, end: Point) -> Line {
    81     pub fn line_to(self, end: Point) -> Line {
    82         Line::new(self, end)
    82         Line::new(self, end)
    83     }
    83     }
    84 
    84 
    85     #[inline]
    85     #[inline]
    86     pub fn ray_to(self, end: Point) -> Ray {
    86     pub fn ray_with_dir(self, direction: Point) -> Ray {
    87         self.line_to(end).to_ray()
    87         Ray::new(self, direction)
    88     }
    88     }
    89 
    89 
    90     #[inline]
    90     #[inline]
    91     pub fn tangent(self) -> i32 {
    91     pub fn tangent(self) -> i32 {
    92         self.y / self.x
    92         self.y / self.x