mirror of
https://github.com/GraphiteEditor/Graphite.git
synced 2026-09-18 07:48:02 +08:00
add overlays,detection,transform for gizmo
This commit is contained in:
@@ -98,6 +98,13 @@ pub fn dvec2_to_point(value: DVec2) -> Point {
|
||||
Point { x: value.x, y: value.y }
|
||||
}
|
||||
|
||||
pub fn get_line_endpoints(line: Line) -> (DVec2, DVec2) {
|
||||
let po = line.p0;
|
||||
let p1 = line.p1;
|
||||
|
||||
(point_to_dvec2(po), point_to_dvec2(p1))
|
||||
}
|
||||
|
||||
pub fn segment_to_handles(segment: &PathSeg) -> BezierHandles {
|
||||
match *segment {
|
||||
PathSeg::Line(_) => BezierHandles::Linear,
|
||||
|
||||
Reference in New Issue
Block a user