jonobr1 / two.js

A renderer agnostic two-dimensional drawing api for the web.
https://two.js.org
MIT License
8.27k stars 454 forks source link

[Enhancement] Add Path.Compound Static Method #696

Open jonobr1 opened 1 year ago

jonobr1 commented 1 year ago

Describe the feature you'd like Create a static method on Two.Path to be able to combine any number different paths and return a new compound path.

const compound = Two.Path.compound(a, b, c, d);

Functionally the code would project every vertex and concatenate them together into one list of vertices.

Additional context Related to the Boolean Operations issue: https://github.com/jonobr1/two.js/issues/596