spine-rigc 2.58.1 → 2.59.0
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/package.json +1 -1
- package/src/mesh.ts +17 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "spine-rigc",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.59.0",
|
|
4
4
|
"description": "AI-authored 2D rigging and animation, verified before it is written. rigc compiles a rig spec into skeleton data in the Spine 4.3 format, gates it with named assertions held to a spine-core round trip's verdicts, and emits nothing that fails. Ships as an agent skill.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
package/src/mesh.ts
CHANGED
|
@@ -2168,6 +2168,11 @@ function cellIslands(cells: Uint8Array, nx: number, ny: number): Array<Array<[nu
|
|
|
2168
2168
|
|
|
2169
2169
|
/**
|
|
2170
2170
|
* The lattice over one part's alpha: cells, one loop, triangles, outline first.
|
|
2171
|
+
* Promised through `rig-c/mesh` (issue #1450). `mask.alpha` is one byte per
|
|
2172
|
+
* source pixel, `threshold` is an alpha byte in 1..255, and `cell` is a whole
|
|
2173
|
+
* number of part-local pixels. Returns `SegmentsLattice`: points in part-local
|
|
2174
|
+
* pixels (y down), dimensionless UVs rounded to six decimals, triangle indices,
|
|
2175
|
+
* the outline vertex count and cell/pass/island counts. No weights are built.
|
|
2171
2176
|
*
|
|
2172
2177
|
* Refuses a part that keeps no cell and a cell that is not a whole number of
|
|
2173
2178
|
* pixels of at least 1; everything else about the geometry follows from the art.
|
|
@@ -2377,6 +2382,10 @@ export interface SegmentsFalloff {
|
|
|
2377
2382
|
|
|
2378
2383
|
/**
|
|
2379
2384
|
* Distance from `p` to the segment `a -> b`, a zero-length segment being its point.
|
|
2385
|
+
* Promised through `rig-c/mesh` (issue #1450). All three points must use the
|
|
2386
|
+
* same coordinate frame and length unit; the returned non-negative distance
|
|
2387
|
+
* uses that unit. The segments compiler supplies setup-world points in part
|
|
2388
|
+
* pixels, measured through its exact setup frame.
|
|
2380
2389
|
*
|
|
2381
2390
|
* `sqrt(dx*dx + dy*dy)` rather than `Math.hypot`, whose last bit can differ:
|
|
2382
2391
|
* a weight is written on a 6-decimal grid, and that is where one ulp becomes a
|
|
@@ -2507,6 +2516,14 @@ export type InfluenceShares =
|
|
|
2507
2516
|
|
|
2508
2517
|
/**
|
|
2509
2518
|
* The shares on one vertex under an `influence` block — see the section header.
|
|
2519
|
+
* The three-argument call is promised through `rig-c/mesh` (issue #1450). `p`
|
|
2520
|
+
* and every segment endpoint share one frame; `radius` uses that frame's length
|
|
2521
|
+
* unit. `bone` indexes the caller's distinct mesh-bone list and `entry` indexes
|
|
2522
|
+
* its authored segment entries. Returned mesh weights use `bone: 'control'`
|
|
2523
|
+
* and `control` for that same distinct-bone index. Returns weights closing at one
|
|
2524
|
+
* on the six-decimal grid, with the pre-cap in-reach bone count; or the nearest
|
|
2525
|
+
* bone and its distance in the input unit when no link reaches the vertex.
|
|
2526
|
+
* The compiler uses exact setup-world positions measured in part pixels.
|
|
2510
2527
|
* `plant` exists for the selftest's negative controls: each key switches one
|
|
2511
2528
|
* step off, so a control can show its own check going red on weights that
|
|
2512
2529
|
* break exactly that step. A build never passes it.
|