Commit Graph

892 Commits

Author SHA1 Message Date
jneem 58aae4f87b
Replace the Boolean Operations node's algorithm with the Linesweeper library (#2670)
* Attempt one-shot n-ary ops

* Make it not crash

* Try to remove more path_bool

* Add quantization

* Update to latest

* Nits

* Code review

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-03-10 22:00:49 -07:00
Timon 095c2a6d47
Add the Pixel Preview render mode (#3881)
* Add pixel preview render mode

* Fix fmt

* Remove unused sampler

* Remove unnecessary mutex

* Code review

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-03-11 02:44:00 +00:00
YohYamasaki 8e52309bb0
Render raster images as outlines in Outline mode (#3831)
* Render raster images as outlines in Outline mode

* Draw a transformed unit-rectangle stroke instead of raster pixels

* Skip creating blend layers for a raster image in Outline mode
  when only blend mode would trigger them

* Rename variable names

* Minor refactor to reduce nesting

* Extract shared outline drawing helper

* Update node-graph/libraries/rendering/src/renderer.rs

Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>

---------

Co-authored-by: Dennis Kobert <dennis@kobert.dev>
Co-authored-by: cubic-dev-ai[bot] <191113872+cubic-dev-ai[bot]@users.noreply.github.com>
2026-03-10 11:23:48 +00:00
Keavon Chambers 9f9dd71e91
Fix vector drawing tool transform space handling (#3872)
* Fix vector drawing tool transform space handling

* Review fixes

* Fix test
2026-03-10 00:58:51 -07:00
Dennis Kobert f06983d072
Fix texture cache region size and broken rendering when tilting the viewport (#3867)
* Fix rotation for render cache

* Simplify code and fix zoom not invalidating cache

* Add constant for quantization amount

* fix region size

* print error when splitting oversized region fails

---------

Co-authored-by: Timon <me@timon.zip>
2026-03-09 23:42:38 +00:00
Keavon Chambers 52d2b38a82 Refactor the TypeScript data flow for full type safety and auto-generation of Rust types (#3865)
* Migrate Specta to Tsify to auto-generate messages.ts, working except colors and widgets

* Adopt the generated FillColor/Color/GradientStops

* Fix widget typing

* Separate WidgetGroup enum variants into wrapper structs

* Small rename

* Simplify widgets further

* Clean up message type references

* Switch type imports to the auto-generated file

* Remove lowercase serde rename

* Fix FillChoice deserialization

* Fix small regression from #3837

* Improve type safety

* Make WidgetSpan type-safe

* More cleanup and type safety

* More type safety

* More type safety

* Get the rest to type-check without errors; improve widget builder macro to have optional icons; improve Svelte 5 configs

* Cargo fmt

* Fix imports

* Update outdated readme info

* Fix lint command rename references

* Fix typos

* One more typos fix

* Remove unnecessary dep: prefix from the edited Cargo.toml files

* Remove excess parts from Cargo.toml

* Fix compiling on desktop

* Revert "Remove excess parts from Cargo.toml"

This reverts commit 6b711117b3a5d5d8a3ee20f36a43bc74930b7c82.

* Update dev docs with simpler, more accurate instructions
2026-03-09 16:35:04 -07:00
Ayush Amawate fbd2658148
Replace deprecated criterion::black_box with std::hint::black_box (#3860)
* replace deprecated criterion::black_box with std::hint::black_box

* gemini code review suggestions

Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>

* apply formating

---------

Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
2026-03-08 10:40:55 +00:00
Dennis Kobert 3d1491ce92
Add animated GIF file export to Graphene CLI (#3846)
* Add gif file export via graphene cli

* Add check for negative fps numbers
2026-03-08 10:33:40 +00:00
Timon 5d22292072
Replace `npm` build script with new `cargo run` tool (#3832)
* move nix flake to root

* cargo run tool

* use thiserror in third-party-licenses tool

* prefere panic over exit

* Add automatic dependency check to cargo run tool

* Skip dependecies that are not needed for the current task

* Fixup

* Fixup

* fix windows

* Fixup

* improve usage text

* Fix linux bundle

* add graphen-cli

* fix build profile

* fix

* release profile should not include debug infos

* Review

* remove profiling profile

was redundent with release

* rename to cargo-run tool

* improve consistency

* rename deps to requirements

* fix

* return success when showing usage
2026-03-07 13:26:19 +00:00
Keavon Chambers 7cc3097acd
Make the Outline render mode draw with consistent stroke thickness at any viewport zoom (#3848)
* Remove dead code for now-retired SVG implementation

* Implement viewport zoom compensation for thickness
2026-03-02 20:13:05 -08:00
Keavon Chambers a8b5203d6c
Clean up code for drawing overlays to accept sRGB hex codes instead of Color structs (#3839)
* Clean up code for drawing overlays to accept sRGB hex codes instead of Color structs

* Consolidate hex code parsing functions
2026-02-27 14:08:58 -08:00
Keavon Chambers 9ecbfb7110
New nodes: RGBA to Color, HSVA to Color, Hex to Color, and Read Gradient (#3838)
* New nodes: RGBA to Color, HSVA to Color, Hex to Color, and Read Gradient

* Simplify
2026-02-26 18:22:04 -08:00
Keavon Chambers f1cbc4b396
Make the node graph use Table<GradientStops> instead of GradientStops (#3837)
* Switch from GradientStops to Table<GradientStops> in all nodes

* Remove TaggedValue::ColorNotInTable

* Fix bug

Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>

* Add migrations

* Fix default gradient on empty table

* Update demo artwork

---------

Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
2026-02-26 14:07:31 -08:00
Keavon Chambers 81c73d11ff
Clean up duplicated code used for recursively flattening graphic types (#3836)
* Reduce recusive flattening algorithm duplication

* Generalize further

* Avoid code duplication in the 'Flatten Path' node

* Avoid cloning

* Include intermediate levels of alpha blending composition
2026-02-26 05:36:23 -08:00
Keavon Chambers cde7d5f951
New nodes: Colors to Gradient, Flatten Color, and Flatten Gradient (#3835)
* New nodes: Colors to Gradient, Flatten Color, and Flatten Gradient

* Fix Data panel not showing GradientStops

* Fix wrong category
2026-02-26 03:44:12 -08:00
Timon da7437c023
Reimplement notice file generation for third-party licenses through Rust, now with CEF credits (#3808) 2026-02-26 11:12:28 +00:00
Keavon Chambers 4090f6c980 Tweak short-term roadmap details 2026-02-25 21:40:36 -08:00
Keavon Chambers 82cf8eb369
Upgrade Linebender and related dependencies (#3819)
Co-authored-by: Timon <me@timon.zip>
2026-02-25 19:10:57 +00:00
Keavon Chambers 4a6cdffd84
Add draggable diamond midpoint gizmos to the Gradient tool (#3826) 2026-02-24 20:25:15 -08:00
Dennis Kobert 7250b091d5
Fix the UI scaling factor invalidating the render cache (#3818)
* Fix ui scaling messing up render cache

* Review

---------

Co-authored-by: Timon <me@timon.zip>
2026-02-24 12:41:42 +00:00
Keavon Chambers 691d965bcf
Add support for gradients with midpoints and add draggable diamonds to the color picker dialog (#3813)
* Refactor GradientStops to use struct-of-arrays and include midpoint

* Implement interaction and rendering

* Make color picker saturation-value color picking snap to original position and show both axis lines

Make color picker saturation-value color picking snap to original position and show both axis lines

* Add graphite:midpoint attribute to SVG exports

* Add graphite:midpoint parsing to SVG importer
2026-02-23 19:21:51 -08:00
Dennis Kobert a1c1039ea1
Fix path tool overlays (#3810)
* Add vector data to merge function

Use destructuring to avoid issues like this in the future

* Remove unnecessary explict copying
2026-02-23 09:17:00 +00:00
Keavon Chambers 71b4c98de7 Fix logarithmic spiral not drawing if Inner Radius is 0 2026-02-22 13:48:19 -08:00
Keavon Chambers 9f2c8713ff
Add the SVG Preview render mode in place of the Vello option in the preferences (#3797)
* Remove Vello from preferences

* Add the Render Mode: SVG Preview radio button

* Remove SVG outline renderer

* Add a tooltip explaination when disabled in unsupported browsers

* Fix Eyedropper tool to support Outline render mode

* Use #[allow(clippy::too_many_arguments)] instead of tuple

* Rerun nodegraph when max render area is changed

---------

Co-authored-by: Dennis Kobert <dennis@kobert.dev>
2026-02-22 20:27:26 +00:00
Dennis Kobert 0531769c41
Cache Vello render output as stitchable textures (#3722)
* WIP render caching

* Hook up render cache to render pipeline

* Fixed offsets

* Initial cleanup

* Integrate cache with context invalidation

* Cleanup

* Improve rounding and reduce tile size to fix vello not rendering

* Include pointer position in cache key

* Avoid unwraps and zero sized textures

* Destroy textures after blitting to surface

* Fix context dependencies

* Exclude footprint from render params

* Batch animation frame messages

* Add vello max render size to preference dialogue

* Remove unused import

* Reorder vello preference

* Clean up preferences dialog

* Apply review suggestions

* Cap max render region size

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-02-22 10:12:50 +00:00
Keavon Chambers 7ca6470656
Rename the repeat nodes to replace "Instance" terminology with "Repeat" (#3794)
* WIP

* Move the Mirror node from the module 'vector' to 'graphic'

* Update demo art

* Fix failing tests

Fix tests
2026-02-20 22:10:59 -08:00
Keavon Chambers 5a1503fc98 New node: Flatten Raster 2026-02-20 13:35:12 -08:00
Dennis Kobert ba177c4c5d
Generalize the 'Map Vector' node as 'Map' with support for all graphical types (#3793)
* Rename Map Vector to Map

* Fix compilation errors

* Move to the Graphic module and add Read {Graphic, Raster, Color} nodes

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-02-20 21:33:02 +00:00
Keavon Chambers bd1c54907d
Rename nodes from "Instance ___" -> "Read ___" and "Instance Map" -> "Map Vector" (#3792)
* Rename nodes from "Instance ___" -> "Read ___" and "Instance Map" -> "Map Vector"

* Update leftover references and demo artwork

* Simplify logic

* Fix test
2026-02-20 08:52:36 +00:00
Keavon Chambers da278e0264 New node: Map Points
Also resolves #3217
2026-02-19 14:37:35 -08:00
Keavon Chambers 258748ec51
Swap the default placement order of Fill and Stroke nodes in layers (#3789) 2026-02-19 13:15:11 -08:00
Keavon Chambers 5d5993bcca
Fix opacity not being included in alpha of Fill type when converted from Table<Color> (#3785)
* Fix opacity not being included in alpha of Fill type when converted from Table<Color>

* Avoid unwrap, I guess
2026-02-18 09:21:02 +00:00
Kulcode ed20f4ac9b
Fix outline rendering mode to draw shapes as black or white based on contrast with their artboard's color (#3724)
* contrast

* Update

* error corrected

* changes

* Fix

* fix-2

* cleanup-2

* Formatting

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-02-16 23:38:12 +00:00
Oliver Davies 20e12edd45
New node: Pack Strips (#3246)
* Added basic pack by bounds node

Apply suggestion from @Keavon

Co-authored-by: Keavon Chambers <keavon@keavon.com>

* Add support for choosing rows/columns strip direction

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-02-16 09:07:03 +00:00
Vatsal Kumar 82f7dc7062
Improve the Shape tool's arrow drawing controls (#3650)
* fixed the arrow's parameters

Signed-off-by: krVatsal <kumarvatsal34@gmail.com>

* shifted the arrow's origin to its tail

Signed-off-by: krVatsal <kumarvatsal34@gmail.com>

* modified arrow shapetype fucntion to be like other shapes

* fixed rust formatting

* Remove misleading part of comment referencing the origin

---------

Signed-off-by: krVatsal <kumarvatsal34@gmail.com>
Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-02-15 21:35:20 +00:00
MotherBoardMage 87739ff877
Fix solidify stroke node ignoring transforms applied before stroke node (#3683)
* fix: solidify_stroke node now applies transformations before calculating the stroke

* Check for non-invertible transform

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2026-02-15 20:32:22 +00:00
Kulcode 84f91eb795
Fix Text node/tool max width/height bounding box calculation (#3628)
* Fix: correctly apply max width/height in text bounding box

* bug fix

* Code cleanup

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-02-14 21:27:29 +00:00
Keavon Chambers 8738e59c21
Improve the QR Code node (#3765) 2026-02-14 20:53:29 +00:00
Sahil Gupta 6c10364c8c
Introduce QR Code node (#3565)
Co-authored-by: Timon <me@timon.zip>
2026-02-14 17:50:43 +00:00
Timon 8b67840f0c Desktop: Fix Eyedropper tool (#3764) 2026-02-14 16:44:52 +00:00
Ayush Amawate 119a554260
Fix the Path tool adding a Path node but not applying the change until a second attempt due to wrong segment IDs (#3727)
* Fix SegmentIds lost when no Path node exists

* fix import order

* Use Arc<Vector> in vector_data for regression
2026-02-13 14:40:38 -08:00
0SlowPoke0 ea68d62ec4
Add gizmos for interacting with the Spiral node (#2851)
* made spiral node

* number of turns in decimal and arc-angle implementation

* logarithmic spiral

* unified log and arc spiral into spiral node

* add spiral shape in shape tool

* fix min value and degree unit

* make it compile

* impl turns handle gizmo

* chore : Refactoring PR #2851 for current code base with some fixes

* Code review

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
Co-authored-by: Annonnymmousss <jatin02012006@gmail.com>
2026-02-12 22:33:40 +00:00
Dennis Kobert 5efa81df85
Store click targets in Arc (#3726) 2026-02-06 12:35:32 +00:00
Dennis Kobert 1a9f0a543c
Fix pointer position node (#3725)
Fix PointerPosition traits
2026-02-05 23:43:58 +01:00
Dennis Kobert 3f97ae4c57
Add JSON get node (#3708)
* Add JSON get node

* Return "" on error and print to console
2026-02-03 22:07:46 +00:00
Timon d04def886d
Ensure non-negative lengths for stroke dash pattern (#3710)
Caused Vello rendering to fail
2026-02-03 17:19:31 +00:00
Vishnu Tejas 7e436f48f9
Expose the secondary input for Logical And and Or nodes (#3711) 2026-02-03 14:19:23 +00:00
Dennis Kobert 8e8428a572
Add headers input to http nodes (#3709) 2026-02-03 11:47:53 +00:00
Timon 910fb54c15
Add quantize time nodes (#3703)
add quantize time nodes
2026-02-02 12:55:53 +00:00
Keavon Chambers 390004897b
Add "Loop Level" to the Position context reader node (#3679)
* Add "Loop Level" to the Position context reader node

* Remove InjectPosition
2026-01-28 10:52:39 +00:00
Timon 5fd1a24f16
Desktop: Add Eyedropper tool support with native Vello (#3684)
* mostly done

* fix

* kinda works but tilt and flip broken

* fix footprint

Co-authored-by: James Lindsay <78500760+0HyperCube@users.noreply.github.com>

* Code review

* fix cursor hiding

* Remove console.log

---------

Co-authored-by: James Lindsay <78500760+0HyperCube@users.noreply.github.com>
Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-01-27 01:24:09 +00:00
Keavon Chambers 19e9af3d43
Fix 'Apply Transform' node applying only to anchors but not also handles (#3687) 2026-01-26 12:32:17 -08:00
Timon b4e9d7b9eb
Desktop: Fix bitmap file export not preserving alpha (#3673)
Fix Export not preserving alpha
2026-01-26 13:51:48 +00:00
Mohammed Afreed baig c07124332b
Fix GPU out-of-memory crash by reusing overlay textures (#3614)
* Refactor TargetTexture into proper abstraction with ensure_size() method

* Remove redundant overlays_texture field, use view() directly

* Use if-let syntax in render_vello_scene_to_target_texture to avoid explicit unwrap

* Implement TargetTexture::new() constructor to avoid dummy textures

* fix compile error

* cleanup

* Avoid cloning texture view

---------

Co-authored-by: Timon <me@timon.zip>
Co-authored-by: Dennis Kobert <dennis@kobert.dev>
2026-01-26 12:44:41 +00:00
Keavon Chambers a88342b8da
Add the "Rate" multiplier parameter to the Animation Time node (#3685) 2026-01-26 00:37:15 -08:00
Keavon Chambers 568831bd2f
Fix regression breaking Into/Convert node type coercion (#3681) 2026-01-25 16:26:05 -08:00
Keavon Chambers 7af60e02a3
Add the auto-generated node catalog to the website's user manual (#3662)
* Generate the MVP node catalog in the manual (with some placeholders)

* Implement nearly the rest of everything

* Move to the tools directory and make it generate nicer default values

* Add category descriptions

* Organize file structure and improve type naming

* Improve book table of contents code

* Add collapsing chapter navigation to the book template

* Add to build workflow

* Clean up site structure
2026-01-20 22:52:03 -08:00
Keavon Chambers 5543afd44b
Clean up old website code and files (#3658) 2026-01-19 22:09:51 -08:00
Keavon Chambers 3b55064f44
Add tooltip documentation to the Text node and tidy up node catalog categorization (#3645)
* Add more node doc comments

* Tidy up node categories
2026-01-16 01:27:56 -08:00
Adam Gerhant c60ddcf875
Fix the Text node's Max Width/Height parameters with OptionalF64 losing the value when unticked (#3643)
* WIP

* Fix widget

* Fix migration

* Remove OptionalF64

* Custom attributes for optional f64 widget

* Code review

* Move comments to another PR

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-01-16 06:13:32 +00:00
James Lindsay aadc989134
Include path endpoints as extrema in the Extrude node (#3469)
* Include single connected points as extrema in the extrude node

* Update styling of loading indicator

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-01-14 02:31:18 -08:00
James Lindsay c46060db44
Add a Select tool overlay for the layer origin (#3471)
* Add blue layer origin cross overlay

* Apply suggestion from @Keavon

* Skip layers without local transforms

* Disable the Custom Pivot by default

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-01-14 01:50:03 -08:00
Keavon Chambers 20a595db39 Fix a bug where Transform nodes would cause a reversal of the 'Instance Index' node's 'Loop Level' counting direction 2026-01-13 23:15:42 -08:00
Jo e3ad59ad9c
Add tooltip documentation to web request and brush related nodes (#3427)
* Add tooltip documentation to web request, text, and brush nodes

  - Add descriptive tooltips to web request nodes (GET/POST, string/image conversion, resource loading, image decoding)
  - Add tooltip to GPU rasterization node explaining footprint usage
  - Improve text node tooltip with clearer per_glyph_instances parameter explanation
  - Add tooltips to brush stamp generator and blit operations explaining their internal roles
  - Fix typos in tooltip and variable names (it's→its, perview→preview, instnace→instance)

* Fixed 2 issues with previous changes. Reversed order of documentation about per_glyph_instances. Can it be 3 lines?

* Improve post_request node documentation

Change doc comment to describe the node's purpose rather than focusing
only on the "Discard Result" parameter. Now clearly states this is an
HTTP POST operation with optional async behavior.

* Fix post_request documentation error

Corrected doc comment to say "HTTP POST" instead of "HTTP GET" since
this function performs POST requests with binary data.

* Review changes

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-01-13 08:35:14 +00:00
Adam Gerhant a6052c5819
Replace node definition string-based lookups with DefinitionIdentifier instances (#3451)
* create definition identifier and integrate it

* Bug fixes and code review

* formatting

* Fix migrations

* Fix remove handles migration

* formatting

* Fix test

* Fix tests 2

* fix deserialization

* Code review

* Small fixes

* Consolidate 'Morph' node migrations

* Add old SamplePointsNode name to migrations list

* Fix tests

* Unrelated small fix

* Fix migration crashes

* Fix tests

* Final code review

* fmt

* Add metadata

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-01-12 23:09:43 -08:00
Vatsal Kumar 4fea2b0fe7
Add an arrow to the Shape tool (#3343)
* add arrow shape feature in editor

Signed-off-by: krVatsal <kumarvatsal34@gmail.com>

* fix the arrow tool to show arrow in viewport space

Signed-off-by: krVatsal <kumarvatsal34@gmail.com>

* fix the direction of arrow and make the new arrow node

Signed-off-by: krVatsal <kumarvatsal34@gmail.com>

* updated arrow tool to hae start and end points

Signed-off-by: krVatsal <kumarvatsal34@gmail.com>

* fixed calculate point bug

Signed-off-by: krVatsal <kumarvatsal34@gmail.com>

* fixed some bugs of arrow positioning

Signed-off-by: krVatsal <kumarvatsal34@gmail.com>

* fixed formatting in whole codebase and added fill to arrow

Signed-off-by: krVatsal <kumarvatsal34@gmail.com>

* fix

---------

Signed-off-by: krVatsal <kumarvatsal34@gmail.com>
Co-authored-by: Timon <me@timon.zip>
2026-01-12 00:58:28 +00:00
Kulcode 479688d86b
Fix integer underflow in Index Points node (#3623)
Fix: Prevent integer underflow in Index Points node
2026-01-11 23:51:55 +00:00
Keavon Chambers 1b91198b28
Fix 'Regular Polygon' and 'Star' shapes incorrectly having cubic handles, not linear (#3606)
Fix shape nodes creating cubic-curved polylines
2026-01-06 20:58:08 -08:00
Youssef Ahmed Hassan Elzedy 9cb856eee4
Feature: Add median filter option to blur node (#3196)
* Add median filter option to blur node:

- Add median parameter to blur function for noise reduction
- Implement median_filter_algorithm with efficient quickselect
- Support gamma space calculations for median filtering
- Preserve edges while removing noise, complementing existing blur options

Feature in Issue: #912

* Optimize median filter algorithm by reusing buffers and improving pixel neighborhood collection

* Add median filter option to blur node:

- Add median parameter to blur function for noise reduction
- Implement median_filter_algorithm with efficient quickselect
- Support gamma space calculations for median filtering
- Preserve edges while removing noise, complementing existing blur options

Feature in Issue: #912

* Optimize median filter algorithm by reusing buffers and improving pixel neighborhood collection

* Improve median filter's NaN handling by using total_cmp for safe comparisons

* Add median filter node for noise reduction

- Create dedicated median_filter node separate from blur functionality
- Implement median_filter_algorithm with efficient quickselect
- Support gamma space calculations for consistency
- Use safe NaN handling with f32::total_cmp to prevent panics
- Optimize performance with memory reuse and O(n) median selection

* Refactor median filter to remove gamma handling and simplify algorithm

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
Co-authored-by: Dennis Kobert <dennis@kobert.dev>
2026-01-06 14:22:11 +01:00
Dennis Kobert e88db022af
Exclude node registry functions from desktop frontend builds (#3584)
* Exclude node registry functions from desktop frontend builds

This reduces compile times and file sizes

* Use early return

* Fix branch name in build-linux pipeline
2026-01-06 12:34:15 +00:00
Timon c2a29470c3
Desktop: Fix serde-based document migrations not being applied in non-Wasm environments (#3580)
Desktop: Fix serde based migrations not beeing applied
2026-01-05 23:45:31 +00:00
Dennis Kobert fafc687d84
Migrate memo nodes to node macro and make implementing other persistent nodes easier (#3552)
* Add #[data] and #[serialize] attributes to node macro

- Add #[data] attribute for struct fields that aren't node parameters
  - Data fields are initialized with Default::default()
  - Passed as references to the underlying function
  - Excluded from registry metadata (internal state)
  - Generic types in data fields allowed without #[implementations]

- Add #[serialize] attribute for custom Node::serialize() implementation
  - Receives references to all data fields
  - Generates serialize() method in Node trait impl

- Conditional derives based on data field presence
  - With data fields: Debug, Clone only
  - Without data fields: Debug, Copy, Clone, PartialEq, Eq, PartialOrd, Ord, Hash

* Refactor Memo and Monitor Node to use node macro

* Move Complex type into type alias

* Fix format

* Update node-graph/nodes/gcore/src/memo.rs

Co-authored-by: Keavon Chambers <keavon@keavon.com>

* Update node-graph/nodes/gcore/src/memo.rs

Co-authored-by: Keavon Chambers <keavon@keavon.com>

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2026-01-05 22:28:02 +01:00
Ayush Amawate 42440c0d0b
Fix rasterize node document leakage with hashmap and eq check (#3550)
* fix: rasterize node document leakage with hashmap and eq check

* Use single Hashmap and ignore source id

* use or_insert_with instead of Entry match

---------

Co-authored-by: Dennis Kobert <dennis@kobert.dev>
2026-01-04 11:33:18 +00:00
James Lindsay 403ab7ba31
Fix math error affecting the linear segment -> polynomial logic (#3562)
Fix typo in the linear segment -> polynomial code
2026-01-02 10:00:02 +00:00
Keavon Chambers 2fa958aa79 Remove generics from the user-facing name for the Vector data type 2026-01-01 21:26:02 -08:00
Keavon Chambers fa45efa9e2
New node: Pointer Position (#3535)
* New node: Pointer Position

* Fix test
2025-12-27 16:02:23 -08:00
Keavon Chambers 9f25c50ca1 Prep for the RC1 release of the desktop app 2025-12-24 22:45:08 -08:00
Keavon Chambers 64ed21f694 Clean up code with better naming 2025-12-21 23:35:00 -08:00
Keavon Chambers 123108c813 Promote vector meshes from experimental by removing it from preferences 2025-12-21 19:33:42 -08:00
Nicholas Liu e73e524f3d
Implement proper fill rendering for vector meshes (#3474)
* Implement branching mesh rendering for SVG

* Patch mesh fill for Vello renderer

* Patch tangent_at_start and tangent_at_end

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-12-21 02:59:37 +00:00
Keavon Chambers 3000519a10 New nodes: 'Reciprocal', 'Angle Between', and 'Angle To' 2025-12-20 02:36:43 -08:00
Keavon Chambers f1e8ebefc5
Improve tooltip docs with Markdown styling and refined math node explanations (#3488) 2025-12-20 01:05:15 -08:00
Keavon Chambers 2d6d054359
Make font selection show a live preview on hover; move its code to the backend (#3487)
* Remove FontInput.svelte

* Move font picking to the backend

* Fix Text tool font choice style turning to "-" on font that doesn't support previous style
2025-12-19 22:17:28 -08:00
Adam Gerhant 6733a24e47
Use more specific node input indexing when displaying invalid input errors (#3415)
* Reduce displayed invalid inputs

* Correct error offset for convert node

* Apply suggestions from code review

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-12-18 10:48:25 +00:00
Dennis Kobert a6f83291b4
We now use normal blending instead of using Mix::Clip / the clip_layer (#3454)
* We now use normal blending instead of using Mix::Clip / the clip_layer

* Revert the revert for the clip using SrcOver
2025-12-07 10:26:24 +00:00
Keavon Chambers fb0fab0622 Update links from graphite.rs to graphite.art 2025-12-06 18:10:27 -08:00
Keavon Chambers e8ebcc2c21
Replace text-only tooltips with custom richly styled tooltips (#3436)
* Replace the title attribute with custom FloatingMenu tooltips

* Separate tooltip labels and descriptions into two styled blocks

* Move keyboard shortcut tooltips to a separate section at the bottom

* Update shortcut key styling in tooltips and hints bar

* Fix .to_string()
2025-11-30 13:32:58 -08:00
Dennis Kobert 406f3d93f3
Add tool for visualizing crate hierarchy (#3315)
* Add tool for visualizing crate hierarchy

* Update crate structure

* Restructure crate viz and integrate crate into workspace

* Remove transitive dependency edges

* Move png / svg creation into the rust binary
2025-11-28 15:34:45 +00:00
James Lindsay 8383a3afac
New node: 'Extrude' (#3414)
* Add extrude node

* Code review

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-11-26 18:50:10 -08:00
James Lindsay 5ebf6d6bc0
Fix StrokePathIter missing some segments (#3413) 2025-11-26 07:03:28 +00:00
Keavon Chambers 9eb8835bd5
Add the 'Blend Shapes' and 'Origins to Polyline' nodes; generalize the 'Morph' node to >2 states (#3405)
* New nodes: 'Morph' and 'Multi-Morph'

* Blend Shapes node

* Add the 'Index Points' node

* Fix failing test
2025-11-25 22:17:55 -08:00
Keavon Chambers d247b81966
Fix regression that reversed indexing of the Loop Level parameter of the 'Instance Index' node (#3421) 2025-11-25 21:32:56 -08:00
Keavon Chambers eb0f019b15
New nodes: 'Reset Transform', 'Replace Transform', 'Count Points', 'Index Points' (#3420)
- Add the 'Reset Transform' and 'Replace Transform' nodes
- Add the 'Count Points' and 'Index Points' nodes
- Make the 'Index Elements' node support negative indexing from the end
- Make the 'Flatten Vector' node's implementation reusable
- Fix crash displaying 0x0 raster image in the Data panel
- Fix the 'Points to Polyline' node not working on two-point objects
2025-11-25 20:41:59 -08:00
Dennis Kobert a932eaedcf
Render artwork at correct resolution when using vello on wasm (#3416)
* Work on fixing rendering for wasm+vello

* Render vello canvas in wasm at the correct resolution

* Cleanup unused surface rendering code

* Remove vector to raster conversion

* Remove desktop changes

* Revert window.rs changes

* Don't round logical coordinates

* Fix desktop compilation + don't round logical coordinates for svg rendering

* Further cleanup

* Compute logical size from acutal physical sizes
2025-11-24 14:23:27 +00:00
Keavon Chambers 6e66c79392
Fix 'Mask' node missing Properties widget; fix crash with 'Brightness/Contrast Classic' node (#3404)
* Fix 'Mask' node missing Properties widget; fix crash with 'Brightness/Contrast Classic' node

Also clean up dead code and improve tooltip for the "-" Properties panel widget fallback.

* format type

---------

Co-authored-by: Adam <adamgerhant@gmail.com>
2025-11-24 09:21:07 +00:00
Timon 548e0df1a1
Desktop: Mac menu workaround (#3398) 2025-11-19 17:13:35 +00:00
Dennis Kobert 788e82a7d0
Add export command to Graphene CLI (#3400)
* Add export command to cli

* Fix format
2025-11-19 17:39:48 +01:00
Dennis Kobert f61aebb777
Add a command to Graphene CLI for listing protonode identifiers (#3399)
* Add proto node name printing

* Add subcommand for printing proto node identifiers

* Address review comments

* Cargo fmt
2025-11-19 11:59:27 +01:00
Adam Gerhant 06484ef4e0
Show red connectors on a type-erroring node and accurate connector colors upstream of it (#3110)
* Refactor TypeSource

* Add complete valid types

* Add invalid type

* Improve valid/complete types and disconnecting

* Code review

* Return types on error

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
2025-11-19 03:00:32 +00:00
Timon 7d739c4542
Post refactor fixup (#3395)
* fixup

* fix feature deps for native
2025-11-18 15:48:45 +00:00