Commit Graph

1902 Commits

Author SHA1 Message Date
Sidharth-Singh10 9acc23d0cc
Add Gradient tool test for dragging the stop rearranges the ordering (#2565) 2025-04-16 13:38:26 +00:00
Mohamed Osama af4f57ef38
Add "Perpendicular to Endpoint" snapping target (#2581)
* Perpendicular snap for line's endpoints

* move comment

* Code review

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-16 12:23:45 +00:00
James Lindsay 435a6daf25
Add the first field-based nodes: 'Instance on Points', 'Instance Position', 'Instance Index', as well as 'Grid' (#2574)
* Basic fields

* Add 'Extract XY' and 'Split Vector2' nodes

* Add 'Instance Index' node

* Fix test again

* Improve grid generator to support rectangular as well

* Avoid crashing

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-16 11:58:59 +00:00
Keavon Chambers 184c009f17 Add memoization to instancer nodes 2025-04-16 04:43:47 -07:00
Adam Gerhant ee6a842a6b
Fix dragging a node onto a secondary input's wire not working (#2583)
Fix dragging onto wire
2025-04-16 01:52:15 -07:00
kythyria a94354df04
New node: Dimensions (#2576)
* Add node for size of bounding box

* Keep rustfmt happy

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-16 01:07:34 +00:00
Dennis Kobert 9a62c1c089
Fix Poisson-disk sampling with negative space from nested subpaths (#2569)
* Fix poisson disk sampling with nested subpaths

Previously all subpaths were considered independently for the poisson disk sampling evaluation. We now check agains all subpaths which might contain the point to fix shapes with holes such as fonts with letters with holes in them

* Fix wasm demo

* Fix counting overlapping areas twice

* Rename shape variables to subpath variants
2025-04-15 13:37:20 +00:00
Sidharth-Singh10 98558c74f4
Add Gradient tool test for dragging an endpoint setting the correct point in the viewport (#2564)
* Add Gradient tool test for dragging an endpoint sets the correct point in the viewport

* add canvas_zoom and transformset to verify correct viewport-space behavior
2025-04-14 19:25:07 +00:00
Dennis Kobert 9b23c7e2db
Update Tauri to v2 and execute only the node graph in native (#2362)
* Migrate tauri app to v2

* Move flake files to sub directory

* Remove unused plugins

* Backport some of the tauri code

* Implement async node graph execution

Only move node runtime to native code

* Always use gpu feature for tauri

* Fix serialization

* Add logging filters

* Enable native window rendering with vello

* Cleanup

* Remove unused editor instance

* Remove changes from vite config

* Remove warnings

* Remove unused files

* Fix most tests

* Cleanup

* Apply frontend lint

* Readd flake.nix

* Fix tests using --all-features

* Code review

* Enable all backends

* Fix monitor node downcast types

* Change debug log to a warning

* Disable shader passthrough

* Cleanup unused imports

* Remove warning

* Update project setup instructions

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-14 11:43:15 +00:00
Keavon Chambers 29479f6e3e Update Cargo dependencies in Cargo.lock 2025-04-13 21:20:55 -07:00
0SlowPoke0 d194c784be
Prevent auto-panning in Pen/Spline tools while drawing without dragging (#2463)
don't autopann when mouse up

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-13 18:21:59 -07:00
Mateo c2a36ce981
Restore auto-panning that #2443 had broken (#2562)
* Fix auto panning

* Clean up comments

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-13 22:19:08 +00:00
Rahat b3d6be9618
Add tests for Line tool with PTZ (#2559)
* cli failing

* cli failing

* Adding tests for line tool with zoom pann and tilt
2025-04-13 20:13:59 +00:00
Mateo 6bc12c8ede
Invalidate cache when unexposing input (#2512) 2025-04-13 19:33:37 +00:00
Rahat 272a5ce0df
Add GRS tests for different types of nested layer multi-selections (#2518)
* cli failing

* cli failing

* test_transform_with_different_selections and groups

* merge conflict

* Use abs_diff_eq in assertions

* Added test 4

* Added test 4

* removed unnecessary changes
2025-04-13 20:06:11 +01:00
mTvare 3e6021fb8f
Fix inability to drag axis-aligned lines (#2561)
* Fix 1 and 3

* Fix 2

* Shape tools refactor

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-13 03:51:40 -07:00
Ellen Gu fdff5d4e5e
Disallow the Gradient tool from applying to raster images (#2456)
* fix gradient on raster graph error

* Remove should panic from gradient ignore raster tag

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-12 18:42:59 -07:00
Adesh Gupta 550ffc3f7f
Fix box selection erroneously including zero-length handles; fix GRS failing on sharp points (#2550)
* Fixed box selection selecting zero length handles

* Fix GRS for sharp points

* Apply suggestions from code review

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-13 01:21:36 +00:00
Keavon Chambers e759e62291 Comment out all remaining active Imaginate code 2025-04-12 17:32:24 -07:00
Keavon Chambers a11f9b36c3 Add the menu bar command: Help > Debug > Reset Node Definitions on Open 2025-04-12 16:56:55 -07:00
Keavon Chambers 100df9a81d Remove 'Memoize Impure' from document node definitions 2025-04-12 05:15:05 -07:00
Keavon Chambers a8a5a1f3fd New node: Sample Gradient 2025-04-12 04:19:46 -07:00
0SlowPoke0 c156c0a4ce
Improve Pen tool segment drawing confirm/cancel behavior (#2555)
* implement enter to end path

* fixed_abort

* added_hints

* edge-case

* Code review

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-12 09:50:35 +00:00
Keavon Chambers 69069ef723
Fix the 'Repeat', 'Circular Repeat', and 'Mirror' nodes to work on point cloud vector data (#2553)
* Include points in bounding box calculations

* Fix unrelated crash from debug assert when reordering root-level folders

* Fix another unrelated crash from debug assert when GRS scaling to size 0

* Fix several vector nodes to respect and propagate local transform space
2025-04-12 02:18:31 -07:00
Sidharth-Singh10 e4d998a400
Add test for double clicking to insert a gradient stop (#2527)
gradient tool test: Double click to insert a gradient stop

Co-authored-by: James Lindsay <78500760+0HyperCube@users.noreply.github.com>
2025-04-11 14:26:07 +00:00
Keavon Chambers 0d10ad2161 Revert double-click to open node catalog from #2423 because it occurs even outside the graph 2025-04-10 14:55:35 -07:00
Keavon Chambers 855acf7f85 Update website now that GSoC applications are closed 2025-04-10 06:38:43 -07:00
kythyria c137e44b71
Fix the 'Bounding Box' node crashing on empty or single-point vector data input (#2529)
* Make Bounding Box have empty output on empty input

Fixes a crash when using the text tool and the Text node is connected to
a Bounding Box node.

* Use .map().unwrap_or_default()

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-10 02:48:44 -07:00
Utsav Singh 93f7004ece
Make the node catalog, originating from a wire dropped in the graph, filter for valid types (#2423)
* Add InputType based filtering capabilites to NodeCatalog.
Send InputTypes through SendUiMetadata under
odeTypes.
Update NodeCatalog.svelte component to support 	ype based filtering.
Update ContextMenuData to support compatibleType as an input to the searchTerm for the NodeCatalog.
Update Graph.svelte component to support new ContextMenuData enum types.
Send CompatibleType data from rust backend on wire drag and release to NodeCatalog to already show filtered data.

* Add InputType based filtering capabilites to NodeCatalog.
Send InputTypes through SendUiMetadata under
odeTypes.
Update NodeCatalog.svelte component to support 	ype based filtering.
Update ContextMenuData to support compatibleType as an input to the searchTerm for the NodeCatalog.
Update Graph.svelte component to support new ContextMenuData enum types.
Send CompatibleType data from rust backend on wire drag and release to NodeCatalog to already show filtered data.

* Open NodeCatalog on DoubleClick in empty node graph area

* Capture Node implementations and filter out uncatogrised nodes before sending metadata.
Update NodeCatalog Search filter to support single type search alongside name and category search

* Take union of DocumentNodeTypes and registered node implementations, Update missing categories and make sure to remove nodes with empty categories

* Code review

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-09 01:07:35 -07:00
Adesh Gupta 8b0f16e74c
Make GRS rotation (R) angle overlay label show values between -360° and 360° (#2473)
* Fixes issues

* Revert changes

* Viewing angle using R

* Revert other fix so it can be its own PR

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-09 06:15:31 +00:00
Sidharth-Singh10 b38d725d98
Add input hints to interactions in the node graph (#2415)
* node_graph: add hints in status bar

* allow in-progress interactions

* Fix node graph hints not restoring after panning operation

* Code review

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-09 05:50:48 +00:00
Sidharth-Singh10 3c1ec45188
Add option to adjust viewport zoom rate in the preferences dialog (#2420)
* zoom rate preference

* Add generic range mapping functions for improved reusability

* cleanup

* Map zoom slider's default value of 50 to the original zoom rate (0.005)

* use . instead of .0 for whole-number floats

* Refactor zoom rate mapping to use a fixed reference point and adjustable curve steepness

* Code review

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-08 07:51:46 +00:00
0SlowPoke0 6a8386d1e9
Improve Pen tool handle dragging with Tab swapping, Ctrl angle locking, and directly dragging the closing endpoint in handle (#2452)
* added handle_types and refactored the handle_adjustments

* anchor move refactor

* code-todo-fix

* removed-draw-mode

* kind of works need to figure out snapping

* some refactoring

* refactor+overlays..need to fix the snapping and dragging

* added docs

* got stuck in space move

* fixed all issues

* comments and small fixes

* completed last issue and refactor

* major fixes and improv

* fixed edge cases

* edge cases fixed

* fix edge cases and add docs

* Code review pass

* rename ,bug fixes

* Add terminology diagram

* Add Ctrl "Lock Angle" hint

* Rename other hint

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-07 23:26:51 -07:00
Ellen Gu 32aee1ebf9
Add Vello support for Outline view mode rendering; add non_scaling to strokes (SVG, not yet Vello) (#2455)
* fix noise pattern parameter issue

* removed the commented out line

* Fix outline mode stroke width not consistent

* add non scaling stroke option

* Fix backward compatibility

* Clean Debug Message

* clean code

* clean code 2

* Add vello outline support

* Code review

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-07 00:02:11 +00:00
Sidharth-Singh10 3c425d9a71
Fix Gradient tool always re-selecting its end point after any click/drag (#2472)
fix  gradient tool incorrectly selecting end point on pointer up

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-06 15:14:19 -07:00
Utsav Singh 56fafa942a
Fix the 'Mask' node from always erroring (#2474)
Fix mask node upstream input calculation.

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-06 14:33:25 -07:00
Rahat 1001ec2740
Add test for scaling objects to zero without any crash (#2491)
* Add test for scaling objects to zero

* added non zero scale after near zero scale to check if everything is working ifine

* unnecessary change

* cli failing

* chore: upgrade openssl to fix RUSTSEC-2025-0022

* cli failing

* new changes
2025-04-06 14:42:15 +01:00
James Lindsay e11b57a7af
Add tests for gradient drawing with transformations (#2481)
* Test gradient drawing with transformations

* Fix bad import

* Fix merge conflicts

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-06 10:35:20 +00:00
mTvare f003d5d0db
Fix Line/Spline tools being offset when drawing in an artboard not at the origin (#2489)
* Fix line overlays not showing up for horizontal/vertical line

* Fix spline tool transform

* Fix line tool transform

* Fix pivot following mouse even after confirm

* cargo fmt

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-06 03:06:03 -07:00
0SlowPoke0 2f22ce500c
Fix a bug in #2419 (Add recursive folder expand/collapse to the Layers panel) (#2494)
recursive-collapse-fix and clippy-fix

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-06 02:44:10 -07:00
Oliver Davies 81db769737
Minor fixes for 'Round Corners' and 'Mirror' nodes (#2510)
* Fix round corners node not properly maintaing click targets, added keep_original bool to mirror node

* Fixed fix for the theta angle

* Add upgrade script for Mirror node

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-06 02:00:55 -07:00
kythyria 412dfc293a
Make the 'Tangent Inverse' node accept DVec2 in lieu of the separate atan2 node (#2516)
* Make the Tangent Inverse node accept DVec2

If given a DVec2 it will be atan2 instead of normal atan.

* Remove the now-redundant atan2 node

* Doc comment

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-06 01:32:02 -07:00
James Lindsay 86e6923a7c
Make CI audit security advisories daily instead of in each PR (#2425)
* Only run cargo deny on the main branch

* Run cargo-deny once per day instead of per-commit

* Still check licenses in the build-ci
2025-04-06 07:33:12 +00:00
Mateo a6d3c06641
Fix bug introduced in #2511 (#2513)
Fix issue when extending existing paths

Co-authored-by: Starklosch <45690579+Starklosch@users.noreply.github.com>
2025-04-04 22:23:26 -07:00
Mateo c486c6e3e3
Fix Pen tool creates single anchor path (#2511)
* Delete layer if path has a single anchor

* Remove unnecessary layer reference from pen state
2025-04-03 19:41:51 +00:00
Rahat 6de235f80c
Test that select tool GRS works with only one anchor (#2502)
* one-anchor-point-testing implementation

* merge conflict

* merge conflict

* ci cd error
2025-04-02 21:31:29 +01:00
prathmesh703 fb17b9389c
Add tests for drawing lines with ctrl, shift, and alt (#2490)
* test_tool_line

* Test-line-tool

* ALT-test-case

* formatted

---------

Co-authored-by: doxe-2611 <kolpe2611@gmail.com>
2025-04-02 17:48:13 +00:00
Dennis Kobert 8d8e2edc5f
Add 'Freeze Real Time' and 'Boundless Footprint' nodes as alternatives to using 'Memoize Impure' (#2509)
* WIP debugging

* Only create parent ref if var args are used in context + Cleanup

* Eval nodes with None instead of relying on MemoImpure

* Remove unused imports

* Show parent in debug output

* Remove TODO comment
2025-04-02 11:31:52 +00:00
Keavon Chambers bc03941174 Blog post: Internships for a Rust graphics engine: GSoC 2025 2025-04-02 03:58:24 -07:00
James Lindsay 9dcab8823d
Blog post: Graphite progress report (Q4 2024) (#2169)
* Q4 blog draft

* Make all the change messages descriptive for readers

* More

* And more

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-04-01 23:59:50 -07:00