mirror of
https://github.com/GraphiteEditor/Graphite.git
synced 2026-10-08 07:48:11 +08:00
Bezier-rs: Add normal and tangent to subpath (#1003)
tangent and normal for subpath Co-authored-by: Rob Nadal <Robnadal44@gmail.com>
This commit is contained in:
committed by
Keavon Chambers
co-authored by
Rob Nadal
parent
beab0f01c6
commit
511a8aa164
@@ -24,6 +24,14 @@ const subpathFeatures = {
|
||||
mouseLocation ? subpath.project(mouseLocation[0], mouseLocation[1]) : subpath.to_svg(),
|
||||
triggerOnMouseMove: true,
|
||||
},
|
||||
Tangent: {
|
||||
callback: (subpath: WasmSubpathInstance, options: Record<string, number>): string => subpath.tangent(options.t),
|
||||
sliderOptions: [tSliderOptions],
|
||||
},
|
||||
Normal: {
|
||||
callback: (subpath: WasmSubpathInstance, options: Record<string, number>): string => subpath.normal(options.t),
|
||||
sliderOptions: [tSliderOptions],
|
||||
},
|
||||
"Intersect (Line Segment)": {
|
||||
callback: (subpath: WasmSubpathInstance): string =>
|
||||
subpath.intersect_line_segment([
|
||||
|
||||
Reference in New Issue
Block a user