-
Notifications
You must be signed in to change notification settings - Fork 27
Added curve Support #85
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Added curve Support #85
Conversation
Signed-off-by: SplinterSword <[email protected]>
|
@SplinterSword can you add loom recording |
Signed-off-by: SplinterSword <[email protected]>
|
Sorry @saurabhraghuvanshii I didn't see this message I will discuss it in today's meeting |
|
@SplinterSword it'll helpful you can show demo |
|
Yeah I plan to |
Signed-off-by: SplinterSword <[email protected]>
Signed-off-by: SplinterSword <[email protected]>
Signed-off-by: SplinterSword <[email protected]>
Signed-off-by: SplinterSword <[email protected]>
Signed-off-by: SplinterSword <[email protected]>
Signed-off-by: SplinterSword <[email protected]>
Signed-off-by: SplinterSword <[email protected]>
Signed-off-by: SplinterSword <[email protected]>
Signed-off-by: SplinterSword <[email protected]>
Signed-off-by: SplinterSword <[email protected]>
Signed-off-by: SplinterSword <[email protected]>
|
@SplinterSword, do you think that you can get deployment previews working for this site? // @Rajesh-Nagarajan-11 |
|
@leecalcote If you want I will start working on deployment previews. |
Signed-off-by: SplinterSword <[email protected]>
Signed-off-by: SplinterSword <[email protected]>
Signed-off-by: SplinterSword <[email protected]>
|
This forum is to discuss how to import the custom shape on kanvas. I would like some help regarding this as I couldn't find the appropriate docs to import the custom shape to kanvas. |
|
@SplinterSword |
Notes for Reviewers
Summary
This PR adds support for curved shapes by first generating an SVG path (
d) representation of the shape and then converting that path into normalized polygon point pairs, preserving compatibility with Cytoscape node shapes. SVG paths are retained only as an intermediate and rendering/editing aid and are not used as the canonical shape representation.Design Details
Path-first shape generation
Shapes are initially constructed as SVG paths (
dstrings), allowing curve definitions similar to vector design tools.Path → polygon conversion
The generated path is sampled and flattened into straight-line segments, producing a list of polygon point pairs (
x1 y1 x2 y2 ...).Normalization
The resulting polygon points are normalized to a coordinate space centered at
(0,0)and constrained to the[-1, 1]range, which matches Cytoscape’s polygon shape requirements.Canonical format
Normalized polygon point pairs are used as the primary stored and exported shape format. SVG paths are generated only for preview and editing and are not consumed downstream.
Features Added
Compatibility
Consumes only normalized polygon point pairs; no SVG path commands or Bézier curves are passed to Cytoscape.
Validation
[-1, 1]bounds.📹 Demo
Shape.builder.mp4
Notes
Please let me know if further validation or changes are needed.
Signed commits