@thi.ng/geom 3.4.20 → 3.4.22

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Change Log
2
2
 
3
- - **Last updated**: 2022-10-28T19:08:39Z
3
+ - **Last updated**: 2022-11-23T22:46:54Z
4
4
  - **Generator**: [thi.ng/monopub](https://thi.ng/monopub)
5
5
 
6
6
  All notable changes to this project will be documented in this file.
@@ -19,14 +19,14 @@ and/or version bumps of transitive dependencies.
19
19
 
20
20
  #### 🚀 Features
21
21
 
22
- - add AABB support for intersects() ([768dddd](https://github.com/thi-ng/umbrella/commit/768dddd))
23
- - update warpPoints() args, add docs ([50cb467](https://github.com/thi-ng/umbrella/commit/50cb467))
24
- - update edges(), support more types ([3e1b340](https://github.com/thi-ng/umbrella/commit/3e1b340))
22
+ - add IAttributed impls for all shape types ([ccb40f1](https://github.com/thi-ng/umbrella/commit/ccb40f1))
25
23
  - add new transform ops & helpers ([cd8217c](https://github.com/thi-ng/umbrella/commit/cd8217c))
26
24
  - add applyTransforms(), rotate(), scale()
27
25
  - add internal helpers
28
26
  - update transform() rect coercion (now => Quad, previous Polygon)
29
- - add IAttributed impls for all shape types ([ccb40f1](https://github.com/thi-ng/umbrella/commit/ccb40f1))
27
+ - update edges(), support more types ([3e1b340](https://github.com/thi-ng/umbrella/commit/3e1b340))
28
+ - update warpPoints() args, add docs ([50cb467](https://github.com/thi-ng/umbrella/commit/50cb467))
29
+ - add AABB support for intersects() ([768dddd](https://github.com/thi-ng/umbrella/commit/768dddd))
30
30
 
31
31
  #### 🩹 Bug fixes
32
32
 
@@ -42,10 +42,10 @@ and/or version bumps of transitive dependencies.
42
42
 
43
43
  #### 🚀 Features
44
44
 
45
- - update bounds() to support opt. margin ([8cdc372](https://github.com/thi-ng/umbrella/commit/8cdc372))
46
45
  - update rect/aabb, add new factory fns ([f74e377](https://github.com/thi-ng/umbrella/commit/f74e377))
47
46
  - add ...WithMargin() factory fns
48
47
  - add AABBLike.offset() impls
48
+ - update bounds() to support opt. margin ([8cdc372](https://github.com/thi-ng/umbrella/commit/8cdc372))
49
49
 
50
50
  ### [3.2.1](https://github.com/thi-ng/umbrella/tree/@thi.ng/geom@3.2.1) (2022-04-07)
51
51
 
@@ -59,9 +59,9 @@ and/or version bumps of transitive dependencies.
59
59
 
60
60
  #### 🚀 Features
61
61
 
62
- - update/refactor various shape ops ([0e3b99a](https://github.com/thi-ng/umbrella/commit/0e3b99a))
63
- - add BPatch type, ctors and warp fn ([ea81cb5](https://github.com/thi-ng/umbrella/commit/ea81cb5))
64
62
  - add opt. bleed attrib for `svgDoc()` ([fb3ed1e](https://github.com/thi-ng/umbrella/commit/fb3ed1e))
63
+ - add BPatch type, ctors and warp fn ([ea81cb5](https://github.com/thi-ng/umbrella/commit/ea81cb5))
64
+ - update/refactor various shape ops ([0e3b99a](https://github.com/thi-ng/umbrella/commit/0e3b99a))
65
65
 
66
66
  ## [3.1.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/geom@3.1.0) (2021-11-17)
67
67
 
@@ -92,9 +92,9 @@ and/or version bumps of transitive dependencies.
92
92
 
93
93
  #### ♻️ Refactoring
94
94
 
95
- - update imports in all tests/pkgs ([effd591](https://github.com/thi-ng/umbrella/commit/effd591))
96
95
  - update imports in all pkgs ([5fa2b6f](https://github.com/thi-ng/umbrella/commit/5fa2b6f))
97
96
  - add .js suffix for all relative imports
97
+ - update imports in all tests/pkgs ([effd591](https://github.com/thi-ng/umbrella/commit/effd591))
98
98
 
99
99
  # [3.0.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/geom@3.0.0) (2021-10-12)
100
100
 
@@ -115,25 +115,25 @@ and/or version bumps of transitive dependencies.
115
115
 
116
116
  #### ♻️ Refactoring
117
117
 
118
- - rename/restructure internals ([94622fe](https://github.com/thi-ng/umbrella/commit/94622fe))
119
- - remove internal fns from pkg exports
120
- - restructure package ([ca56975](https://github.com/thi-ng/umbrella/commit/ca56975))
121
- - migrate/lift `/src/ctors` source files to `/src` for easier use
122
- - restructure package ([2439102](https://github.com/thi-ng/umbrella/commit/2439102))
123
- - migrate/lift `/src/ops` source files to `/src` for easier use
124
- - sideeffect-free defmulti specs ([2721c1d](https://github.com/thi-ng/umbrella/commit/2721c1d))
118
+ - update all tests in _all_ pkgs ([8b582bc](https://github.com/thi-ng/umbrella/commit/8b582bc))
119
+ - update all to use [@thi.ng/testament](https://github.com/thi-ng/umbrella/tree/main/packages/testament)
120
+ - update all test stubs ([f2d6d53](https://github.com/thi-ng/umbrella/commit/f2d6d53))
121
+ - update imports ([5ef5559](https://github.com/thi-ng/umbrella/commit/5ef5559))
122
+ - remove obsolete import ([7893fd0](https://github.com/thi-ng/umbrella/commit/7893fd0))
123
+ - update imports (transducers) ([25b674f](https://github.com/thi-ng/umbrella/commit/25b674f))
125
124
  - update deps & imports in various pkgs ([e1cf29e](https://github.com/thi-ng/umbrella/commit/e1cf29e))
126
125
  - largely related to recent updates/restructuring of these packages:
127
126
  - api
128
127
  - defmulti
129
128
  - errors
130
129
  - logger
131
- - update imports (transducers) ([25b674f](https://github.com/thi-ng/umbrella/commit/25b674f))
132
- - remove obsolete import ([7893fd0](https://github.com/thi-ng/umbrella/commit/7893fd0))
133
- - update imports ([5ef5559](https://github.com/thi-ng/umbrella/commit/5ef5559))
134
- - update all test stubs ([f2d6d53](https://github.com/thi-ng/umbrella/commit/f2d6d53))
135
- - update all tests in _all_ pkgs ([8b582bc](https://github.com/thi-ng/umbrella/commit/8b582bc))
136
- - update all to use [@thi.ng/testament](https://github.com/thi-ng/umbrella/tree/main/packages/testament)
130
+ - sideeffect-free defmulti specs ([2721c1d](https://github.com/thi-ng/umbrella/commit/2721c1d))
131
+ - restructure package ([2439102](https://github.com/thi-ng/umbrella/commit/2439102))
132
+ - migrate/lift `/src/ops` source files to `/src` for easier use
133
+ - restructure package ([ca56975](https://github.com/thi-ng/umbrella/commit/ca56975))
134
+ - migrate/lift `/src/ctors` source files to `/src` for easier use
135
+ - rename/restructure internals ([94622fe](https://github.com/thi-ng/umbrella/commit/94622fe))
136
+ - remove internal fns from pkg exports
137
137
 
138
138
  ### [2.1.29](https://github.com/thi-ng/umbrella/tree/@thi.ng/geom@2.1.29) (2021-09-03)
139
139
 
@@ -157,12 +157,12 @@ and/or version bumps of transitive dependencies.
157
157
 
158
158
  #### 🛑 Breaking changes
159
159
 
160
+ - fix [#256](https://github.com/thi-ng/umbrella/issues/256) replace enum w/ type alias ([67988ad](https://github.com/thi-ng/umbrella/commit/67988ad))
161
+ - BREAKING CHANGE: replace SegmentType w/ type alias
160
162
  - fix [#256](https://github.com/thi-ng/umbrella/issues/256) replace Type enum w/ alias ([ef7ba74](https://github.com/thi-ng/umbrella/commit/ef7ba74))
161
163
  - BREAKING CHANGE: replace Type enum returned by IShape.type w/ string consts
162
164
  - update all shape classes
163
165
  - update all ops/multimethod dispatches
164
- - fix [#256](https://github.com/thi-ng/umbrella/issues/256) replace enum w/ type alias ([67988ad](https://github.com/thi-ng/umbrella/commit/67988ad))
165
- - BREAKING CHANGE: replace SegmentType w/ type alias
166
166
 
167
167
  #### 🩹 Bug fixes
168
168
 
@@ -173,15 +173,15 @@ and/or version bumps of transitive dependencies.
173
173
 
174
174
  #### ♻️ Refactoring
175
175
 
176
- - update type-only imports ([b8e96cc](https://github.com/thi-ng/umbrella/commit/b8e96cc))
177
176
  - update type-only imports in various tests/pkgs ([3fd9c24](https://github.com/thi-ng/umbrella/commit/3fd9c24))
177
+ - update type-only imports ([b8e96cc](https://github.com/thi-ng/umbrella/commit/b8e96cc))
178
178
 
179
179
  ### [1.13.1](https://github.com/thi-ng/umbrella/tree/@thi.ng/geom@1.13.1) (2020-11-24)
180
180
 
181
181
  #### 🩹 Bug fixes
182
182
 
183
- - add missing translate() impls for Cubic/Quadratic ([fe4c027](https://github.com/thi-ng/umbrella/commit/fe4c027))
184
183
  - update whitespace check in pathFromSvg() ([2ce5ec1](https://github.com/thi-ng/umbrella/commit/2ce5ec1))
184
+ - add missing translate() impls for Cubic/Quadratic ([fe4c027](https://github.com/thi-ng/umbrella/commit/fe4c027))
185
185
 
186
186
  ## [1.13.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/geom@1.13.0) (2020-10-03)
187
187
 
@@ -197,8 +197,8 @@ and/or version bumps of transitive dependencies.
197
197
 
198
198
  #### ♻️ Refactoring
199
199
 
200
- - update fitIntoBounds() fns ([19095b0](https://github.com/thi-ng/umbrella/commit/19095b0))
201
200
  - de-dupe asCubic() for polygon/polyline ([65ea389](https://github.com/thi-ng/umbrella/commit/65ea389))
201
+ - update fitIntoBounds() fns ([19095b0](https://github.com/thi-ng/umbrella/commit/19095b0))
202
202
 
203
203
  ### [1.11.7](https://github.com/thi-ng/umbrella/tree/@thi.ng/geom@1.11.7) (2020-08-28)
204
204
 
@@ -211,14 +211,14 @@ and/or version bumps of transitive dependencies.
211
211
 
212
212
  #### 🚀 Features
213
213
 
214
- - add PathBuilderOpts, update Path.toHiccup() ([deb9892](https://github.com/thi-ng/umbrella/commit/deb9892))
215
- - add support to disable auto-splitting paths in PathBuilder
216
- - update toHiccup() impl to support multiple `M` cmds
217
214
  - add/update clipVertex() impls ([a87c31c](https://github.com/thi-ng/umbrella/commit/a87c31c))
218
215
  - add support for `Line` and `Group` shape types
219
216
  - update boundary arg type to support raw point arrays
220
217
  (rather than only `IShape`). this allows for certain optimizations,
221
218
  esp. for group impl.
219
+ - add PathBuilderOpts, update Path.toHiccup() ([deb9892](https://github.com/thi-ng/umbrella/commit/deb9892))
220
+ - add support to disable auto-splitting paths in PathBuilder
221
+ - update toHiccup() impl to support multiple `M` cmds
222
222
 
223
223
  #### 🩹 Bug fixes
224
224
 
@@ -232,9 +232,9 @@ and/or version bumps of transitive dependencies.
232
232
 
233
233
  #### 🚀 Features
234
234
 
235
+ - add rectFromCentroid() ([7837961](https://github.com/thi-ng/umbrella/commit/7837961))
235
236
  - add offset() & initial impls ([819afd1](https://github.com/thi-ng/umbrella/commit/819afd1))
236
237
  - add impls for circle, line, rect
237
- - add rectFromCentroid() ([7837961](https://github.com/thi-ng/umbrella/commit/7837961))
238
238
 
239
239
  #### ♻️ Refactoring
240
240
 
@@ -250,9 +250,9 @@ and/or version bumps of transitive dependencies.
250
250
 
251
251
  #### 🚀 Features
252
252
 
253
+ - add transformVertices() op ([ef68a27](https://github.com/thi-ng/umbrella/commit/ef68a27))
253
254
  - update asPolyline() impls ([cca8574](https://github.com/thi-ng/umbrella/commit/cca8574))
254
255
  - add arc & quadratic support
255
- - add transformVertices() op ([ef68a27](https://github.com/thi-ng/umbrella/commit/ef68a27))
256
256
 
257
257
  ### [1.8.4](https://github.com/thi-ng/umbrella/tree/@thi.ng/geom@1.8.4) (2020-03-06)
258
258
 
@@ -264,8 +264,8 @@ and/or version bumps of transitive dependencies.
264
264
 
265
265
  #### 🚀 Features
266
266
 
267
- - add cubic polyline impls ([263f2f9](https://github.com/thi-ng/umbrella/commit/263f2f9))
268
- - add fitIntoBounds3, fix [#202](https://github.com/thi-ng/umbrella/issues/202), [#206](https://github.com/thi-ng/umbrella/issues/206) ([19be3fa](https://github.com/thi-ng/umbrella/commit/19be3fa))
267
+ - add intersectionAABB/Rect() ([ecc9706](https://github.com/thi-ng/umbrella/commit/ecc9706))
268
+ - add edges() impl for AABB ([b800686](https://github.com/thi-ng/umbrella/commit/b800686))
269
269
  - add Points3 and supporting ops ([7e1adb7](https://github.com/thi-ng/umbrella/commit/7e1adb7))
270
270
  - points3() ctor
271
271
  - area()
@@ -276,8 +276,8 @@ and/or version bumps of transitive dependencies.
276
276
  - transform()
277
277
  - translate()
278
278
  - vertices()
279
- - add edges() impl for AABB ([b800686](https://github.com/thi-ng/umbrella/commit/b800686))
280
- - add intersectionAABB/Rect() ([ecc9706](https://github.com/thi-ng/umbrella/commit/ecc9706))
279
+ - add fitIntoBounds3, fix [#202](https://github.com/thi-ng/umbrella/issues/202), [#206](https://github.com/thi-ng/umbrella/issues/206) ([19be3fa](https://github.com/thi-ng/umbrella/commit/19be3fa))
280
+ - add cubic polyline impls ([263f2f9](https://github.com/thi-ng/umbrella/commit/263f2f9))
281
281
 
282
282
  #### 🩹 Bug fixes
283
283
 
@@ -285,8 +285,8 @@ and/or version bumps of transitive dependencies.
285
285
 
286
286
  #### ♻️ Refactoring
287
287
 
288
- - update imports ([69e9ed1](https://github.com/thi-ng/umbrella/commit/69e9ed1))
289
288
  - update geom-clip deps & imports ([4fe4bfe](https://github.com/thi-ng/umbrella/commit/4fe4bfe))
289
+ - update imports ([69e9ed1](https://github.com/thi-ng/umbrella/commit/69e9ed1))
290
290
 
291
291
  ### [1.7.7](https://github.com/thi-ng/umbrella/tree/@thi.ng/geom@1.7.7) (2019-11-09)
292
292
 
@@ -298,14 +298,14 @@ and/or version bumps of transitive dependencies.
298
298
 
299
299
  #### ♻️ Refactoring
300
300
 
301
- - update PCLike copy() impls, add copyShape() helper ([bc20135](https://github.com/thi-ng/umbrella/commit/bc20135))
302
- - asCubic() Arc impl (re-use cubicFromArc) ([df5c881](https://github.com/thi-ng/umbrella/commit/df5c881))
303
- - add pclike(), simplify shape factory fns ([ef0d102](https://github.com/thi-ng/umbrella/commit/ef0d102))
301
+ - split api.ts, extract PathBuilder / pathFromSVG ([071c346](https://github.com/thi-ng/umbrella/commit/071c346))
302
+ - improve internal re-use PathBuilder ([c8ef0cf](https://github.com/thi-ng/umbrella/commit/c8ef0cf))
304
303
  - add internal helpers for improved re-use ([b3dc83f](https://github.com/thi-ng/umbrella/commit/b3dc83f))
305
304
  - add copyAttribs()
306
305
  - add pointArraysAsShapes()
307
- - improve internal re-use PathBuilder ([c8ef0cf](https://github.com/thi-ng/umbrella/commit/c8ef0cf))
308
- - split api.ts, extract PathBuilder / pathFromSVG ([071c346](https://github.com/thi-ng/umbrella/commit/071c346))
306
+ - add pclike(), simplify shape factory fns ([ef0d102](https://github.com/thi-ng/umbrella/commit/ef0d102))
307
+ - asCubic() Arc impl (re-use cubicFromArc) ([df5c881](https://github.com/thi-ng/umbrella/commit/df5c881))
308
+ - update PCLike copy() impls, add copyShape() helper ([bc20135](https://github.com/thi-ng/umbrella/commit/bc20135))
309
309
 
310
310
  ### [1.7.3](https://github.com/thi-ng/umbrella/tree/@thi.ng/geom@1.7.3) (2019-08-16)
311
311
 
@@ -324,13 +324,13 @@ and/or version bumps of transitive dependencies.
324
324
 
325
325
  #### 🚀 Features
326
326
 
327
- - add/update transform impls: arc, circle, ellipse, path, rect ([e77e7c2](https://github.com/thi-ng/umbrella/commit/e77e7c2))
328
- - arc, circle, ellipse now converted to paths, instead of polygons
329
- - add ellipse support for asCubic() ([4247801](https://github.com/thi-ng/umbrella/commit/4247801))
330
- - add asPath(), update pathFromCubics() to accept opt attribs ([980af9f](https://github.com/thi-ng/umbrella/commit/980af9f))
327
+ - add polygon impl for asCubic(), add pathFromCubics() ([2faec7f](https://github.com/thi-ng/umbrella/commit/2faec7f))
331
328
  - add asCubic() impls for circle, group, rect ([5ca4166](https://github.com/thi-ng/umbrella/commit/5ca4166))
332
329
  - re-use arc impl from geom-splines
333
- - add polygon impl for asCubic(), add pathFromCubics() ([2faec7f](https://github.com/thi-ng/umbrella/commit/2faec7f))
330
+ - add asPath(), update pathFromCubics() to accept opt attribs ([980af9f](https://github.com/thi-ng/umbrella/commit/980af9f))
331
+ - add ellipse support for asCubic() ([4247801](https://github.com/thi-ng/umbrella/commit/4247801))
332
+ - add/update transform impls: arc, circle, ellipse, path, rect ([e77e7c2](https://github.com/thi-ng/umbrella/commit/e77e7c2))
333
+ - arc, circle, ellipse now converted to paths, instead of polygons
334
334
 
335
335
  #### 🩹 Bug fixes
336
336
 
@@ -340,10 +340,10 @@ and/or version bumps of transitive dependencies.
340
340
 
341
341
  #### 🚀 Features
342
342
 
343
+ - enable TS strict compiler flags (refactor) ([aa10de0](https://github.com/thi-ng/umbrella/commit/aa10de0))
343
344
  - TS strictNullChecks, update various classes & ops ([636dea7](https://github.com/thi-ng/umbrella/commit/636dea7))
344
345
  - make attribs field optional in all shape types
345
346
  - update return types of various fns to potentially return undefined
346
- - enable TS strict compiler flags (refactor) ([aa10de0](https://github.com/thi-ng/umbrella/commit/aa10de0))
347
347
 
348
348
  #### 🩹 Bug fixes
349
349
 
@@ -367,8 +367,8 @@ and/or version bumps of transitive dependencies.
367
367
 
368
368
  #### 🚀 Features
369
369
 
370
- - add inscribedSquare*() fns ([b1790b3](https://github.com/thi-ng/umbrella/commit/b1790b3))
371
370
  - add AABB impls for vertices() & volume() ([a9ba010](https://github.com/thi-ng/umbrella/commit/a9ba010))
371
+ - add inscribedSquare*() fns ([b1790b3](https://github.com/thi-ng/umbrella/commit/b1790b3))
372
372
 
373
373
  ### [1.2.2](https://github.com/thi-ng/umbrella/tree/@thi.ng/geom@1.2.2) (2019-02-15)
374
374
 
@@ -390,20 +390,20 @@ and/or version bumps of transitive dependencies.
390
390
 
391
391
  #### ♻️ Refactoring
392
392
 
393
- - minor update clippedLine() ([4b85288](https://github.com/thi-ng/umbrella/commit/4b85288))
393
+ - remove obsolete/extracted internal ops, update publics ([fb532b8](https://github.com/thi-ng/umbrella/commit/fb532b8))
394
+ - update to use geom-api types ([b223603](https://github.com/thi-ng/umbrella/commit/b223603))
395
+ - remove obsolete/migrated fns, update deps, readme ([df8332d](https://github.com/thi-ng/umbrella/commit/df8332d))
396
+ - update pointInside & classifyPoint impls (delegate) ([226645f](https://github.com/thi-ng/umbrella/commit/226645f))
394
397
  - swap Group ctor & factory arg order ([6d14f2b](https://github.com/thi-ng/umbrella/commit/6d14f2b))
395
398
  - first attribs, then children...
396
- - update pointInside & classifyPoint impls (delegate) ([226645f](https://github.com/thi-ng/umbrella/commit/226645f))
397
- - remove obsolete/migrated fns, update deps, readme ([df8332d](https://github.com/thi-ng/umbrella/commit/df8332d))
398
- - update to use geom-api types ([b223603](https://github.com/thi-ng/umbrella/commit/b223603))
399
- - remove obsolete/extracted internal ops, update publics ([fb532b8](https://github.com/thi-ng/umbrella/commit/fb532b8))
399
+ - minor update clippedLine() ([4b85288](https://github.com/thi-ng/umbrella/commit/4b85288))
400
400
 
401
401
  ## [1.1.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/geom@1.1.0) (2019-01-22)
402
402
 
403
403
  #### 🚀 Features
404
404
 
405
- - add asPolyline() multi-fn ([c602379](https://github.com/thi-ng/umbrella/commit/c602379))
406
405
  - add attrib support to PathBuilder ([a017b10](https://github.com/thi-ng/umbrella/commit/a017b10))
406
+ - add asPolyline() multi-fn ([c602379](https://github.com/thi-ng/umbrella/commit/c602379))
407
407
 
408
408
  #### 🩹 Bug fixes
409
409
 
@@ -429,25 +429,25 @@ and/or version bumps of transitive dependencies.
429
429
 
430
430
  #### 🚀 Features
431
431
 
432
- - re-add barycentric conversions, collation mappers (still unused) ([db4a201](https://github.com/thi-ng/umbrella/commit/db4a201))
433
- - update closestPoint(), add support for Arc ([63b3a5d](https://github.com/thi-ng/umbrella/commit/63b3a5d))
434
- - add arcPointAt() helper, refactor Arc, minor other updates ([0e5e776](https://github.com/thi-ng/umbrella/commit/0e5e776))
435
- - add splitNearPoint() for line & polyline, update Sampler ([910529d](https://github.com/thi-ng/umbrella/commit/910529d))
436
- - add splitNearPoint(), Sampler.closestT(), internal restructure ([1d754eb](https://github.com/thi-ng/umbrella/commit/1d754eb))
437
- - add flip() impls ([56f6037](https://github.com/thi-ng/umbrella/commit/56f6037))
438
- - add pointAt() impls for Cubic/Quadratic ([ebc9a98](https://github.com/thi-ng/umbrella/commit/ebc9a98))
439
- - add closestPoint() impls for splines, line, polygons, polyline ([eaf1a1b](https://github.com/thi-ng/umbrella/commit/eaf1a1b))
440
- - add transform() impls for Cubic/Quadratic ([627e20d](https://github.com/thi-ng/umbrella/commit/627e20d))
441
- - add clippedLine(), minor update liangBarsky() ([d763621](https://github.com/thi-ng/umbrella/commit/d763621))
442
- - add/update edges(), pointInside() & classifyPoint() impls ([e834597](https://github.com/thi-ng/umbrella/commit/e834597))
443
- - re-add vertices() impls for Cubic/Quadratic ([f5a53ca](https://github.com/thi-ng/umbrella/commit/f5a53ca))
444
- - re-add pathFromSvg() ([3c9a7b0](https://github.com/thi-ng/umbrella/commit/3c9a7b0))
445
- - add intersection checks & intersects() multi-fn ([66267e2](https://github.com/thi-ng/umbrella/commit/66267e2))
446
- - re-add tessellators ([f1f428a](https://github.com/thi-ng/umbrella/commit/f1f428a))
447
- - add clipConvex, scatter, warpPoints ([d09cc79](https://github.com/thi-ng/umbrella/commit/d09cc79))
448
- - add path builder, path & arc op impls ([61cfb0f](https://github.com/thi-ng/umbrella/commit/61cfb0f))
449
- - re-add arc, cubic, quadratic ops, splitAt & other ops ([fea8fbe](https://github.com/thi-ng/umbrella/commit/fea8fbe))
450
432
  - add temp geom3 package (another refactored version of geom2) ([c0e3a0b](https://github.com/thi-ng/umbrella/commit/c0e3a0b))
433
+ - re-add arc, cubic, quadratic ops, splitAt & other ops ([fea8fbe](https://github.com/thi-ng/umbrella/commit/fea8fbe))
434
+ - add path builder, path & arc op impls ([61cfb0f](https://github.com/thi-ng/umbrella/commit/61cfb0f))
435
+ - add clipConvex, scatter, warpPoints ([d09cc79](https://github.com/thi-ng/umbrella/commit/d09cc79))
436
+ - re-add tessellators ([f1f428a](https://github.com/thi-ng/umbrella/commit/f1f428a))
437
+ - add intersection checks & intersects() multi-fn ([66267e2](https://github.com/thi-ng/umbrella/commit/66267e2))
438
+ - re-add pathFromSvg() ([3c9a7b0](https://github.com/thi-ng/umbrella/commit/3c9a7b0))
439
+ - re-add vertices() impls for Cubic/Quadratic ([f5a53ca](https://github.com/thi-ng/umbrella/commit/f5a53ca))
440
+ - add/update edges(), pointInside() & classifyPoint() impls ([e834597](https://github.com/thi-ng/umbrella/commit/e834597))
441
+ - add clippedLine(), minor update liangBarsky() ([d763621](https://github.com/thi-ng/umbrella/commit/d763621))
442
+ - add transform() impls for Cubic/Quadratic ([627e20d](https://github.com/thi-ng/umbrella/commit/627e20d))
443
+ - add closestPoint() impls for splines, line, polygons, polyline ([eaf1a1b](https://github.com/thi-ng/umbrella/commit/eaf1a1b))
444
+ - add pointAt() impls for Cubic/Quadratic ([ebc9a98](https://github.com/thi-ng/umbrella/commit/ebc9a98))
445
+ - add flip() impls ([56f6037](https://github.com/thi-ng/umbrella/commit/56f6037))
446
+ - add splitNearPoint(), Sampler.closestT(), internal restructure ([1d754eb](https://github.com/thi-ng/umbrella/commit/1d754eb))
447
+ - add splitNearPoint() for line & polyline, update Sampler ([910529d](https://github.com/thi-ng/umbrella/commit/910529d))
448
+ - add arcPointAt() helper, refactor Arc, minor other updates ([0e5e776](https://github.com/thi-ng/umbrella/commit/0e5e776))
449
+ - update closestPoint(), add support for Arc ([63b3a5d](https://github.com/thi-ng/umbrella/commit/63b3a5d))
450
+ - re-add barycentric conversions, collation mappers (still unused) ([db4a201](https://github.com/thi-ng/umbrella/commit/db4a201))
451
451
 
452
452
  #### 🩹 Bug fixes
453
453
 
@@ -459,9 +459,9 @@ and/or version bumps of transitive dependencies.
459
459
 
460
460
  #### ♻️ Refactoring
461
461
 
462
- - update withAttribs() return type ([8e2c8b5](https://github.com/thi-ng/umbrella/commit/8e2c8b5))
463
- - add tessellate() multi-fn, move/rename tessellators ([499e14b](https://github.com/thi-ng/umbrella/commit/499e14b))
464
462
  - update imports, fix tests ([c41b96f](https://github.com/thi-ng/umbrella/commit/c41b96f))
463
+ - add tessellate() multi-fn, move/rename tessellators ([499e14b](https://github.com/thi-ng/umbrella/commit/499e14b))
464
+ - update withAttribs() return type ([8e2c8b5](https://github.com/thi-ng/umbrella/commit/8e2c8b5))
465
465
 
466
466
  ### [0.2.11](https://github.com/thi-ng/umbrella/tree/@thi.ng/geom@0.2.11) (2019-01-02)
467
467
 
@@ -492,10 +492,9 @@ and/or version bumps of transitive dependencies.
492
492
 
493
493
  #### 🚀 Features
494
494
 
495
- - add/update tessellate() impls ([fa87f1e](https://github.com/thi-ng/umbrella/commit/fa87f1e))
496
- - add/update factory fns, arg handling, tessel, poly area ([555fc51](https://github.com/thi-ng/umbrella/commit/555fc51))
497
- - add/update various shape impls & ops ([3a20ef3](https://github.com/thi-ng/umbrella/commit/3a20ef3))
498
- - re-import & refactor partial port of [@thi.ng/geom](https://github.com/thi-ng/umbrella/tree/main/packages/geom) (clojure) ([d655ec2](https://github.com/thi-ng/umbrella/commit/d655ec2))
495
+ - update all shape types, add interfaces & ops, update tests ([9c27c77](https://github.com/thi-ng/umbrella/commit/9c27c77))
496
+ - add ICollate & ICopy impls, re-add/update convexHull2 ([3b1bf64](https://github.com/thi-ng/umbrella/commit/3b1bf64))
497
+ - re-add Arc2, update Circle2, update helper fns ([aa6b120](https://github.com/thi-ng/umbrella/commit/aa6b120))
499
498
  - add/update interfaces & impls ([2657df6](https://github.com/thi-ng/umbrella/commit/2657df6))
500
499
  - add CollateOpts, update collate() in both containers
501
500
  - add generics for IVertices
@@ -503,12 +502,13 @@ and/or version bumps of transitive dependencies.
503
502
  - update edges(), vertices() for Arc2 & Circle2
504
503
  - add .toJSON() impls
505
504
  - add [@thi.ng/checks](https://github.com/thi-ng/umbrella/tree/main/packages/checks) dep
506
- - re-add Arc2, update Circle2, update helper fns ([aa6b120](https://github.com/thi-ng/umbrella/commit/aa6b120))
507
- - add ICollate & ICopy impls, re-add/update convexHull2 ([3b1bf64](https://github.com/thi-ng/umbrella/commit/3b1bf64))
508
- - update all shape types, add interfaces & ops, update tests ([9c27c77](https://github.com/thi-ng/umbrella/commit/9c27c77))
505
+ - re-import & refactor partial port of [@thi.ng/geom](https://github.com/thi-ng/umbrella/tree/main/packages/geom) (clojure) ([d655ec2](https://github.com/thi-ng/umbrella/commit/d655ec2))
506
+ - add/update various shape impls & ops ([3a20ef3](https://github.com/thi-ng/umbrella/commit/3a20ef3))
507
+ - add/update factory fns, arg handling, tessel, poly area ([555fc51](https://github.com/thi-ng/umbrella/commit/555fc51))
508
+ - add/update tessellate() impls ([fa87f1e](https://github.com/thi-ng/umbrella/commit/fa87f1e))
509
509
 
510
510
  #### ♻️ Refactoring
511
511
 
512
- - update deps & [@thi.ng/math](https://github.com/thi-ng/umbrella/tree/main/packages/math) imports ([ffea836](https://github.com/thi-ng/umbrella/commit/ffea836))
513
- - update arg handling, update readme ([2e9f048](https://github.com/thi-ng/umbrella/commit/2e9f048))
514
512
  - add interfaces, split out common.ts into /func folder ([9fb2091](https://github.com/thi-ng/umbrella/commit/9fb2091))
513
+ - update arg handling, update readme ([2e9f048](https://github.com/thi-ng/umbrella/commit/2e9f048))
514
+ - update deps & [@thi.ng/math](https://github.com/thi-ng/umbrella/tree/main/packages/math) imports ([ffea836](https://github.com/thi-ng/umbrella/commit/ffea836))
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thi.ng/geom",
3
- "version": "3.4.20",
3
+ "version": "3.4.22",
4
4
  "description": "Functional, polymorphic API for 2D geometry types & SVG generation",
5
5
  "type": "module",
6
6
  "module": "./index.js",
@@ -35,40 +35,40 @@
35
35
  "tool:bpatch": "tools:node-esm tools/bpatch.ts"
36
36
  },
37
37
  "dependencies": {
38
- "@thi.ng/api": "^8.4.5",
39
- "@thi.ng/arrays": "^2.4.1",
40
- "@thi.ng/associative": "^6.2.15",
41
- "@thi.ng/checks": "^3.3.2",
42
- "@thi.ng/defmulti": "^2.1.20",
43
- "@thi.ng/equiv": "^2.1.12",
44
- "@thi.ng/errors": "^2.2.3",
45
- "@thi.ng/geom-api": "^3.3.17",
46
- "@thi.ng/geom-arc": "^2.1.34",
47
- "@thi.ng/geom-clip-line": "^2.1.34",
48
- "@thi.ng/geom-clip-poly": "^2.1.34",
49
- "@thi.ng/geom-closest-point": "^2.1.31",
50
- "@thi.ng/geom-hull": "^2.1.31",
51
- "@thi.ng/geom-isec": "^2.1.34",
52
- "@thi.ng/geom-poly-utils": "^2.3.18",
53
- "@thi.ng/geom-resample": "^2.1.34",
54
- "@thi.ng/geom-splines": "^2.2.8",
55
- "@thi.ng/geom-subdiv-curve": "^2.1.34",
56
- "@thi.ng/geom-tessellate": "^2.1.34",
57
- "@thi.ng/hiccup": "^4.2.22",
58
- "@thi.ng/hiccup-svg": "^4.3.20",
59
- "@thi.ng/math": "^5.3.12",
60
- "@thi.ng/matrices": "^2.1.32",
61
- "@thi.ng/random": "^3.3.14",
62
- "@thi.ng/strings": "^3.3.16",
63
- "@thi.ng/transducers": "^8.3.22",
64
- "@thi.ng/vectors": "^7.5.23"
38
+ "@thi.ng/api": "^8.5.0",
39
+ "@thi.ng/arrays": "^2.4.3",
40
+ "@thi.ng/associative": "^6.2.17",
41
+ "@thi.ng/checks": "^3.3.3",
42
+ "@thi.ng/defmulti": "^2.1.22",
43
+ "@thi.ng/equiv": "^2.1.13",
44
+ "@thi.ng/errors": "^2.2.4",
45
+ "@thi.ng/geom-api": "^3.3.19",
46
+ "@thi.ng/geom-arc": "^2.1.36",
47
+ "@thi.ng/geom-clip-line": "^2.1.36",
48
+ "@thi.ng/geom-clip-poly": "^2.1.36",
49
+ "@thi.ng/geom-closest-point": "^2.1.33",
50
+ "@thi.ng/geom-hull": "^2.1.33",
51
+ "@thi.ng/geom-isec": "^2.1.36",
52
+ "@thi.ng/geom-poly-utils": "^2.3.20",
53
+ "@thi.ng/geom-resample": "^2.1.36",
54
+ "@thi.ng/geom-splines": "^2.2.10",
55
+ "@thi.ng/geom-subdiv-curve": "^2.1.36",
56
+ "@thi.ng/geom-tessellate": "^2.1.36",
57
+ "@thi.ng/hiccup": "^4.2.24",
58
+ "@thi.ng/hiccup-svg": "^4.3.22",
59
+ "@thi.ng/math": "^5.3.14",
60
+ "@thi.ng/matrices": "^2.1.34",
61
+ "@thi.ng/random": "^3.3.16",
62
+ "@thi.ng/strings": "^3.3.18",
63
+ "@thi.ng/transducers": "^8.3.24",
64
+ "@thi.ng/vectors": "^7.5.25"
65
65
  },
66
66
  "devDependencies": {
67
67
  "@microsoft/api-extractor": "^7.33.5",
68
- "@thi.ng/testament": "^0.3.4",
68
+ "@thi.ng/testament": "^0.3.5",
69
69
  "rimraf": "^3.0.2",
70
70
  "tools": "^0.0.1",
71
- "typedoc": "^0.23.18",
71
+ "typedoc": "^0.23.20",
72
72
  "typescript": "^4.8.4"
73
73
  },
74
74
  "keywords": [
@@ -100,8 +100,8 @@
100
100
  "node": ">=12.7"
101
101
  },
102
102
  "files": [
103
- "*.js",
104
- "*.d.ts",
103
+ "./*.js",
104
+ "./*.d.ts",
105
105
  "api",
106
106
  "internal"
107
107
  ],
@@ -380,5 +380,5 @@
380
380
  "thi.ng": {
381
381
  "year": 2013
382
382
  },
383
- "gitHead": "a4b60163a8caddceed5ec1b6b3584d164f61e7b6\n"
383
+ "gitHead": "75ec32ff7f1b7b5e72e7a04ace24732cd5d6c774\n"
384
384
  }
package/dev/arcs.js DELETED
@@ -1,20 +0,0 @@
1
- const g = require("@thi.ng/geom");
2
- const fs = require("fs");
3
-
4
- let a;
5
- const doc = g.asSvg(
6
- g.svgDoc(
7
- { viewBox: "-100 -100 200 200", fill: "none", stroke: "black" },
8
- //(a = g.arcFrom2Points([-50, 0], [0, 50], [50, 50], 0, false, false)),
9
- (a = g.arc([0, 0], 50, 0, 0, Math.PI * 1.5, false, true)),
10
- (b = g.bounds(a)),
11
- [
12
- "text",
13
- { "font-size": 6, fill: "black", stroke: "none" },
14
- [-80, -80],
15
- `${a.pos} ${a.start.toFixed(2)} ${a.end.toFixed(2)}`
16
- ]
17
- )
18
- );
19
-
20
- fs.writeFileSync("circle01.svg", doc);
package/dev/chull.js DELETED
@@ -1,27 +0,0 @@
1
- compute = (data) => {
2
- const shape = g.withAttribs(data.shape, { stroke: "red" });
3
- const pts = g.points(
4
- g.scatter(shape, data.num),
5
- { fill: "#c0f", shape: "circle" }
6
- );
7
- const hull = g.withAttribs(
8
- g.convexHull(pts),
9
- { stroke: "#00f" }
10
- );
11
- const doc = g.svgDoc({ fill: "none" }, shape, pts, hull);
12
- return g.asSvg();
13
- }
14
-
15
- update = (svg) => document.body.innerHTML = svg;
16
-
17
- shape = rstream.stream()
18
- num = rstream.stream()
19
-
20
- rstream.sync({ src: { shape, num } }).transform(tx.map(compute), tx.map(update))
21
-
22
- shape.next(g.circle(200))
23
- num.next(100)
24
-
25
- star = g.star(150, 10, [0.5, 1]);
26
-
27
- shape.next(g.subdivCurve(star, g.SUBDIV_CHAIKIN_CLOSED, 4))