Skip to content

Mesh gradient#4081

Draft
YohYamasaki wants to merge 3 commits into
GraphiteEditor:masterfrom
YohYamasaki:mesh-gradient-poc
Draft

Mesh gradient#4081
YohYamasaki wants to merge 3 commits into
GraphiteEditor:masterfrom
YohYamasaki:mesh-gradient-poc

Conversation

@YohYamasaki

@YohYamasaki YohYamasaki commented Apr 29, 2026

Copy link
Copy Markdown
Contributor

This is a PoC of #3990 at this moment.

Screen.Recording.2026-04-20.at.19.34.40.mov

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces a new "Mesh" gradient type, adding UI support in the gradient tool and implementing an initial SVG rendering path that approximates the mesh by subdividing it into an 8x8 grid of polygons. Feedback identifies critical bugs in the rendering logic, including potential panics if the geometry has fewer than four points or segments and an incorrect return statement that prevents subsequent elements from rendering. Additionally, the reviewer noted that the mesh colors are currently hardcoded and that the Vello and SVG stops table implementations are still placeholders.

Comment thread node-graph/libraries/rendering/src/renderer.rs Outdated
Comment thread node-graph/libraries/rendering/src/renderer.rs
Comment thread node-graph/libraries/rendering/src/renderer.rs
Comment thread node-graph/libraries/rendering/src/renderer.rs Outdated
Comment thread node-graph/libraries/rendering/src/renderer.rs Outdated
@Keavon Keavon force-pushed the master branch 2 times, most recently from 4b7a823 to 847b8e9 Compare May 17, 2026 14:37
@timon-schelling timon-schelling force-pushed the master branch 2 times, most recently from 15fcaac to d5f0140 Compare May 17, 2026 15:37
YohYamasaki and others added 3 commits July 9, 2026 10:26
Approximate Coons patch by creating bilinear gradient in parallelograms.
Each subgrid's color does not have C1 continuity, so we can see
 steps of colors in the strongly skewed scene. This could be
 solved by using bicubic interpolation.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant