Skip to content

Instance tables refactor part 8: Make repeater nodes use pivot not bbox and output instance type not group; rename 'Flatten Vector Elements' to 'Flatten Path' and add 'Flatten Vector' #2697

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

Merged
merged 1 commit into from
Jun 7, 2025

Conversation

Keavon
Copy link
Member

@Keavon Keavon commented Jun 7, 2025

Partly closes #1834.

Nodes that now move the local origin instead of bounding box center, and output the instanced type rather than always being wrapped in a GraphicGroupTable:

  • Instance On Points
  • Instance Repeat
  • Repeat
  • Circular Repeat
  • Copy To Points

TODO: Still needs to have the above description performed, but it involves challenging transforms I wasn't able to figure out:

  • Mirror

Nodes that output VectorDataTable but now also support VectorDataTable as input:

  • Flatten Vector Elements -> Flatten Path (renamed — this produces one vector instance row containing all the original geometry as subpaths)
  • Flatten Vector (new — creates one VectorDataTable with many rows)

…roup; rename 'Flatten Vector Elements' to 'Flatten Path' and add 'Flatten Vector'
Copy link

github-actions bot commented Jun 7, 2025

Performance Benchmark Results

compile_demo_art_iai::compile_group::compile_to_proto with_setup_0:load_from_name(isometric-fountain)
Instructions: 25,051,645 (master) -> 25,054,724 (HEAD) : $$\color{red}+0.01\%$$

Detailed metrics
Baselines:                master|       HEAD
D1mr                     310,587|    311,386          +0.26%
D1mw                      98,885|     98,882          -0.00%
DLmr                      28,672|     28,722          +0.17%
DLmw                      37,758|     39,673          +5.07%
Dr                     6,027,562|  6,027,207          -0.01%
Dw                     4,266,805|  4,266,286          -0.01%
EstimatedCycles       39,192,568| 39,240,797          +0.12%
I1mr                      47,522|     43,412          -8.65%
ILmr                         856|        867          +1.29%
Ir                    25,051,645| 25,054,724          +0.01%
L1hits                34,889,018| 34,894,537          +0.02%
LLhits                   389,708|    384,418          -1.36%
RamHits                   67,286|     69,262          +2.94%
TotalRW               35,346,012| 35,348,217          +0.01%

compile_demo_art_iai::compile_group::compile_to_proto with_setup_1:load_from_name(painted-dreams)
Instructions: 12,246,840 (master) -> 13,046,232 (HEAD) : $$\color{red}+6.53\%$$

Detailed metrics
Baselines:                master|       HEAD
D1mr                     145,484|    155,773          +7.07%
D1mw                      46,855|     49,725          +6.13%
DLmr                         348|        708        +103.45%
DLmw                      14,995|     13,118         -12.52%
Dr                     2,946,128|  3,138,186          +6.52%
Dw                     2,077,287|  2,212,878          +6.53%
EstimatedCycles       18,609,687| 19,743,004          +6.09%
I1mr                      21,949|     21,744          -0.93%
ILmr                         733|        732          -0.14%
Ir                    12,246,840| 13,046,232          +6.53%
L1hits                17,055,967| 18,170,054          +6.53%
LLhits                   198,212|    212,684          +7.30%
RamHits                   16,076|     14,558          -9.44%
TotalRW               17,270,255| 18,397,296          +6.53%

compile_demo_art_iai::compile_group::compile_to_proto with_setup_2:load_from_name(procedural-string-lights)
Instructions: 3,464,216 (master) -> 2,159,043 (HEAD) : $$\color{lime}-37.68\%$$

Detailed metrics
Baselines:                master|       HEAD
D1mr                      40,452|     22,302         -44.87%
D1mw                      12,745|     10,505         -17.58%
DLmr                          19|         17         -10.53%
DLmw                       3,786|      2,455         -35.16%
Dr                       823,769|    494,496         -39.97%
Dw                       581,605|    361,346         -37.87%
EstimatedCycles        5,244,240|  3,260,901         -37.82%
I1mr                       6,453|      4,862         -24.66%
ILmr                         730|        706          -3.29%
Ir                     3,464,216|  2,159,043         -37.68%
L1hits                 4,809,940|  2,977,216         -38.10%
LLhits                    55,115|     34,491         -37.42%
RamHits                    4,535|      3,178         -29.92%
TotalRW                4,869,590|  3,014,885         -38.09%

compile_demo_art_iai::compile_group::compile_to_proto with_setup_3:load_from_name(parametric-dunescape)
Instructions: 12,493,620 (master) -> 12,499,173 (HEAD) : $$\color{red}+0.04\%$$

Detailed metrics
Baselines:                master|       HEAD
D1mr                     153,047|    152,097          -0.62%
D1mw                      50,228|     50,153          -0.15%
DLmr                          42|         45          +7.14%
DLmw                      12,062|     12,050          -0.10%
Dr                     2,974,220|  2,974,044          -0.01%
Dw                     2,123,703|  2,123,857          +0.01%
EstimatedCycles       18,873,813| 18,871,020          -0.01%
I1mr                      20,100|     19,209          -4.43%
ILmr                         855|        842          -1.52%
Ir                    12,493,620| 12,499,173          +0.04%
L1hits                17,368,168| 17,375,615          +0.04%
LLhits                   210,416|    208,522          -0.90%
RamHits                   12,959|     12,937          -0.17%
TotalRW               17,591,543| 17,597,074          +0.03%

compile_demo_art_iai::compile_group::compile_to_proto with_setup_4:load_from_name(red-dress)
Instructions: 29,988,666 (master) -> 29,982,025 (HEAD) : $$\color{lime}-0.02\%$$

Detailed metrics
Baselines:                master|       HEAD
D1mr                     382,823|    381,132          -0.44%
D1mw                     126,879|    126,662          -0.17%
DLmr                      40,763|     40,789          +0.06%
DLmw                      65,377|     62,589          -4.26%
Dr                     7,153,135|  7,152,573          -0.01%
Dw                     5,073,250|  5,072,333          -0.02%
EstimatedCycles       47,668,769| 47,555,605          -0.24%
I1mr                      51,250|     47,537          -7.24%
ILmr                         857|        867          +1.17%
Ir                    29,988,666| 29,982,025          -0.02%
L1hits                41,654,099| 41,651,600          -0.01%
LLhits                   453,955|    451,086          -0.63%
RamHits                  106,997|    104,245          -2.57%
TotalRW               42,215,051| 42,206,931          -0.02%

compile_demo_art_iai::compile_group::compile_to_proto with_setup_5:load_from_name(valley-of-spires)
Instructions: 19,008,977 (master) -> 19,008,507 (HEAD) : $$\color{lime}-0.00\%$$

Detailed metrics
Baselines:                master|       HEAD
D1mr                     235,807|    234,872          -0.40%
D1mw                      76,701|     76,116          -0.76%
DLmr                      12,250|     12,277          +0.22%
DLmw                      28,473|     29,047          +2.02%
Dr                     4,558,964|  4,558,665          -0.01%
Dw                     3,228,492|  3,228,437          -0.00%
EstimatedCycles       29,431,701| 29,434,447          +0.01%
I1mr                      35,119|     32,994          -6.05%
ILmr                         769|        773          +0.52%
Ir                    19,008,977| 19,008,507          -0.00%
L1hits                26,448,806| 26,451,627          +0.01%
LLhits                   306,135|    301,885          -1.39%
RamHits                   41,492|     42,097          +1.46%
TotalRW               26,796,433| 26,795,609          -0.00%

@Keavon Keavon merged commit 53caba4 into master Jun 7, 2025
4 checks passed
@Keavon Keavon deleted the avoid-grouping-in-instancer-nodes branch June 7, 2025 09:24
seam0s-dev pushed a commit to seam0s-dev/Graphite that referenced this pull request Jun 8, 2025
…ox and output instance type not group; rename 'Flatten Vector Elements' to 'Flatten Path' and add 'Flatten Vector' (GraphiteEditor#2697)

Make repeater nodes use pivot not bbox and output instance type not group; rename 'Flatten Vector Elements' to 'Flatten Path' and add 'Flatten Vector'
mTvare6 pushed a commit that referenced this pull request Jun 8, 2025
…ox and output instance type not group; rename 'Flatten Vector Elements' to 'Flatten Path' and add 'Flatten Vector' (#2697)

Make repeater nodes use pivot not bbox and output instance type not group; rename 'Flatten Vector Elements' to 'Flatten Path' and add 'Flatten Vector'
Keavon added a commit that referenced this pull request Jun 20, 2025
…ox and output instance type not group; rename 'Flatten Vector Elements' to 'Flatten Path' and add 'Flatten Vector' (#2697)

Make repeater nodes use pivot not bbox and output instance type not group; rename 'Flatten Vector Elements' to 'Flatten Path' and add 'Flatten Vector'
Moharum1 pushed a commit to Moharum1/Graphite that referenced this pull request Jun 23, 2025
…ox and output instance type not group; rename 'Flatten Vector Elements' to 'Flatten Path' and add 'Flatten Vector' (GraphiteEditor#2697)

Make repeater nodes use pivot not bbox and output instance type not group; rename 'Flatten Vector Elements' to 'Flatten Path' and add 'Flatten Vector'
Keavon added a commit that referenced this pull request Jun 26, 2025
…spacing based on separation or quantity (#2727)

* Added Count point Radio button to property pannel

* Implemented on Count radio button functionality

* Fixed linting and Title case problem

* Fixing more linting problem

* Instance tables refactor part 8: Make repeater nodes use pivot not bbox and output instance type not group; rename 'Flatten Vector Elements' to 'Flatten Path' and add 'Flatten Vector' (#2697)

Make repeater nodes use pivot not bbox and output instance type not group; rename 'Flatten Vector Elements' to 'Flatten Path' and add 'Flatten Vector'

* Refactor the 'Bounding Box' node to use Kurbo instead of Bezier-rs (#2662)

* use kurbo's default accuracy constant

* fix append_bezpath() method

* refactor bounding box node

* fix append bezpath implementation.

* comments

---------

Co-authored-by: Keavon Chambers <[email protected]>

* Add overlays for free-floating anchors on hovered/selected vector layers (#2630)

* Add selection overlay for free-floating anchors

* Add hover overlay for free-floating anchors

* Refactor outline_free_floating anchor

* Add single-anchor click targets on VectorData

* Modify ClickTarget to adapt for Subpath and PointGroup

* Fix Rust formatting

* Remove debug statements

* Add point groups support in VectorDataTable::add_upstream_click_targets

* Improve overlay for free floating anchors

* Remove datatype for nodes_to_shift

* Fix formatting in select_tool.rs

* Lints

* Code review

* Remove references to point_group

* Refactor ManipulatorGroup for FreePoint in ClickTargetGroup

* Rename ClickTargetGroup to ClickTargetType

* Refactor outline_free_floating_anchors into outline

* Adapt TransformCage to disable dragging and rotating on a single anchor layer

* Fix hover on single points

* Fix comments

* Lints

* Code review pass

---------

Co-authored-by: Keavon Chambers <[email protected]>

* Add anchor sliding along adjacent segments in the Path tool (#2682)

* Improved comments

* Add point sliding with approximate t value

* Add similarity calculation

* Numerical approach to fit the curve

* Reliable point sliding for cubic segments

* Fix formatting and clean comments

* Fix cubic with one handle logic

* Cancel on right click and escape

* Two parameter optimization

* Esc/ Right click cancellation

* Code review

* Fix dynamic hints

* Revert selected_points_counts and fix comments

* Code review

---------

Co-authored-by: Keavon Chambers <[email protected]>

* Fix Sample Points node to avoid duplicating endpoints instead of closing its sampled paths (#2714)

* Skip duplicate endpoint and close sampled paths in Sample Points node
Closes #2713

* Comment

---------

Co-authored-by: Keavon Chambers <[email protected]>

* Implemented on Count radio button functionality

* Fixed linting and Title case problem

* The sample count can now work with adaptive spacing

* Readying for production

* Rename to 'Sample Polyline' and add migration

* Upgrade demo artwork

* Add monomorphization

---------

Co-authored-by: Keavon Chambers <[email protected]>
Co-authored-by: Priyanshu <[email protected]>
Co-authored-by: seam0s <[email protected]>
Co-authored-by: Adesh Gupta <[email protected]>
Co-authored-by: Ezbaze <[email protected]>
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.

Tracking Issue: Instances tables
1 participant