rig-parts 2.63.0 → 2.64.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/cli.ts +38 -15
- package/docs/AUTHORING.md +103 -56
- package/docs/STABILITY.md +6 -3
- package/package.json +1 -1
- package/src/build.ts +6 -4
- package/src/check.ts +147 -13
- package/src/localweights.ts +51 -5
- package/src/runstamp.ts +2 -1
- package/src/scene.ts +36 -6
package/cli.ts
CHANGED
|
@@ -55,7 +55,7 @@ import { RETUNE_FILE, RETUNE_SPEC, retuneStage } from './src/retune.ts';
|
|
|
55
55
|
import { checkPainting, DEFAULT_PAINTING_FORM, isPaintingForm, PAINTING_FORMS, paintingFormOf } from './src/paintcheck.ts';
|
|
56
56
|
import { decodePngBytes, readPng, writePng } from './src/raster/png.ts';
|
|
57
57
|
import { REQUIREMENTS_SENTENCE } from './src/requirements.ts';
|
|
58
|
-
import { composeStage, IMAGE_SEP, PLATE, PROVENANCES, SCENE_CAMERA_REPORT_SPEC, SCENE_REPORT_FILE, SCENE_REPORT_SPEC, SCENE_SPEC } from './src/scene.ts';
|
|
58
|
+
import { type ComposeInput, composeStage, IMAGE_SEP, PLATE, PROVENANCES, refusePreviewLoopSeam, SCENE_CAMERA_REPORT_SPEC, SCENE_REPORT_FILE, SCENE_REPORT_SPEC, SCENE_SPEC } from './src/scene.ts';
|
|
59
59
|
import { buildSheet, defaultCaption, type Tile, tilesFrom } from './src/sheet.ts';
|
|
60
60
|
import { loadComparison, requiredProblems, structureLines } from './src/structure.ts';
|
|
61
61
|
import { type ArgvTable, assembleOutputFiles, BUILD_RUN_FILE, CHECK_RUN_FILE, clearComposeRun, clearRunRecord, clearRunStamp, readPackageIdentity, recordArgv, rigOutputFiles, RUN_STAMP_FILE, RUN_STAMP_SPEC, writeRunRecord, writeRunStamp } from './src/runstamp.ts';
|
|
@@ -1046,7 +1046,16 @@ usage:
|
|
|
1046
1046
|
|
|
1047
1047
|
rig-parts compose --scene <scene.json> --out <dir> [--requirements <file.json>] [--accept <bar>[,<bar>...]] [--page-size <px>]
|
|
1048
1048
|
[--loop-seam-bar <channel-delta,pixels> --loop-seam-cap <loops>]
|
|
1049
|
+
[--output-profile preview] [--no-extremes]
|
|
1049
1050
|
The loop seam flags measure the composed idle in check/, as for check.
|
|
1051
|
+
--no-extremes omits the extra extremes renders. --output-profile preview
|
|
1052
|
+
also omits published idle_frames/, contact.png and motion_heat.png, and
|
|
1053
|
+
implies --no-extremes. The gate and check requirements still apply.
|
|
1054
|
+
Opt-in success prints PREVIEW or NO EXTREMES and records output_profile
|
|
1055
|
+
in compose-run.json. When both flags are given, preview takes precedence.
|
|
1056
|
+
Preview uses the stock idle render for checks, then removes it.
|
|
1057
|
+
Preview refuses --loop-seam-bar (COMPOSE_PREVIEW_REQUIRED_CHECK) because
|
|
1058
|
+
check.json binds the first and wrap PNGs that must remain in idle_frames/.
|
|
1050
1059
|
Bind several finished characters into one rig. The scene file (spec
|
|
1051
1060
|
"${SCENE_SPEC}") states the canvas {width, height}, an optional plate
|
|
1052
1061
|
{image, provenance: ${PROVENANCES.join(' | ')}, note?}, the characters
|
|
@@ -1303,7 +1312,7 @@ const TAKES = {
|
|
|
1303
1312
|
'comfy plate': { valued: ['--mode', '--painting', '--mask-from', '--occluder', '--out', '--graph', '--model', '--checkpoint-sha256', '--seed', '--grow', '--steps', '--cfg', '--prompt', '--negative', '--host', '--wait', '--timeout', '--poll'], switches: ['--holes', '--help'] },
|
|
1304
1313
|
inputs: { valued: ['--source', '--config', '--out'], switches: ['--help'] },
|
|
1305
1314
|
build: { valued: ['--config', '--source', '--full', '--head', '--out', '--seam', '--project', '--page-edges', '--pack-shape', '--page-size', '--requirements', '--idle-keys', '--lead-in', '--alt', '--set', '--environment', '--wind-band'], switches: ['--loop', '--seam-pairs', '--keep-stills', '--all-sets', '--no-extremes', '--help'] },
|
|
1306
|
-
compose: { valued: ['--scene', '--out', '--requirements', '--accept', '--page-size', '--loop-seam-bar', '--loop-seam-cap'], switches: ['--help'] },
|
|
1315
|
+
compose: { valued: ['--scene', '--out', '--requirements', '--accept', '--page-size', '--loop-seam-bar', '--loop-seam-cap', '--output-profile'], switches: ['--no-extremes', '--help'] },
|
|
1307
1316
|
'mesh-draft': { valued: ['--config', '--parts', '--out', '--requirements', '--idle-keys', '--page-edges', '--pack-shape', '--page-size'], switches: ['--more-triangles', '--help'] },
|
|
1308
1317
|
'mesh-stats': { valued: ['--config', '--parts'], switches: ['--help'] },
|
|
1309
1318
|
remesh: { valued: ['--rig', '--config', '--parts', '--part', '--mesh', '--delta', '--out', '--requirements', '--idle-keys', '--page-edges', '--pack-shape', '--page-size', '--input-check'], switches: ['--record-input-check', '--help'] },
|
|
@@ -1633,15 +1642,22 @@ function cmdRig(args: string[]): number {
|
|
|
1633
1642
|
* the spawn from here. A call that fails carries which rigc ran it, path and
|
|
1634
1643
|
* version ({@link rigcRunnerAt}, issue #337), and every refusal quoting it says so.
|
|
1635
1644
|
*/
|
|
1636
|
-
/**
|
|
1637
|
-
function flags(args: string[], command: Command, required: readonly string[]): Map<string, string> | string {
|
|
1645
|
+
/** Read the command's required and optional `--flag value` pairs, and collect its bare switches in `on` when supplied. A string is a usage error. */
|
|
1646
|
+
function flags(args: string[], command: Command, required: readonly string[], on?: Set<string>): Map<string, string> | string {
|
|
1638
1647
|
const got = new Map<string, string>();
|
|
1639
|
-
|
|
1648
|
+
const switches: readonly string[] = TAKES[command].switches;
|
|
1649
|
+
for (let i = 0; i < args.length; i++) {
|
|
1640
1650
|
const flag = args[i];
|
|
1651
|
+
if (on !== undefined && switches.includes(flag)) {
|
|
1652
|
+
if (on.has(flag)) return `${flag} is given twice`;
|
|
1653
|
+
on.add(flag);
|
|
1654
|
+
continue;
|
|
1655
|
+
}
|
|
1641
1656
|
if (!takesValued(command, flag)) return notTaken(command, flag);
|
|
1642
1657
|
if (args[i + 1] === undefined) return `${flag} needs a value`;
|
|
1643
1658
|
if (got.has(flag)) return `${flag} is given twice`;
|
|
1644
1659
|
got.set(flag, args[i + 1]);
|
|
1660
|
+
i++;
|
|
1645
1661
|
}
|
|
1646
1662
|
for (const k of required) if (!got.has(k)) return `${command} needs ${k} <value>`;
|
|
1647
1663
|
return got;
|
|
@@ -2605,15 +2621,28 @@ function cmdBuild(args: string[]): number {
|
|
|
2605
2621
|
}
|
|
2606
2622
|
|
|
2607
2623
|
function cmdCompose(args: string[]): number {
|
|
2608
|
-
const
|
|
2624
|
+
const on = new Set<string>();
|
|
2625
|
+
const f = flags(args, 'compose', ['--scene', '--out'], on);
|
|
2609
2626
|
if (typeof f === 'string') return usage(f);
|
|
2627
|
+
const profile = f.get('--output-profile');
|
|
2628
|
+
if (profile !== undefined && profile !== 'preview') return usage(`--output-profile ${JSON.stringify(profile)}; preview is required when this flag is given`);
|
|
2629
|
+
const outputProfile = profile ?? (on.has('--no-extremes') ? 'no-extremes' : undefined);
|
|
2610
2630
|
const loopSeam = parseLoopSeamFlags(f);
|
|
2611
2631
|
if (typeof loopSeam === 'string') return usage(loopSeam);
|
|
2612
2632
|
const out = f.get('--out') as string;
|
|
2613
2633
|
clearComposeRun(out);
|
|
2614
|
-
let
|
|
2634
|
+
let input: ComposeInput;
|
|
2615
2635
|
try {
|
|
2616
|
-
size = parsePageSize(f.get('--page-size'));
|
|
2636
|
+
const size = parsePageSize(f.get('--page-size'));
|
|
2637
|
+
const req = f.get('--requirements');
|
|
2638
|
+
const accept = f.get('--accept');
|
|
2639
|
+
input = {
|
|
2640
|
+
scene: f.get('--scene') as string, out, ...(size === undefined ? {} : { pageSize: size }),
|
|
2641
|
+
...(req === undefined ? {} : { requirements: req }), ...(accept === undefined ? {} : { accept: accept.split(',') }),
|
|
2642
|
+
...(loopSeam === undefined ? {} : { loopSeam }),
|
|
2643
|
+
...(outputProfile === undefined ? {} : { outputProfile }),
|
|
2644
|
+
};
|
|
2645
|
+
refusePreviewLoopSeam(input);
|
|
2617
2646
|
} catch (err) {
|
|
2618
2647
|
return printRefusal(err);
|
|
2619
2648
|
}
|
|
@@ -2625,14 +2654,8 @@ function cmdCompose(args: string[]): number {
|
|
|
2625
2654
|
}
|
|
2626
2655
|
const scratch = mkdtempSync(join(tmpdir(), 'rig-parts-compose-'));
|
|
2627
2656
|
try {
|
|
2628
|
-
const req = f.get('--requirements');
|
|
2629
|
-
const accept = f.get('--accept');
|
|
2630
2657
|
const r = composeStage(
|
|
2631
|
-
|
|
2632
|
-
scene: f.get('--scene') as string, out, ...(size === undefined ? {} : { pageSize: size }),
|
|
2633
|
-
...(req === undefined ? {} : { requirements: req }), ...(accept === undefined ? {} : { accept: accept.split(',') }),
|
|
2634
|
-
...(loopSeam === undefined ? {} : { loopSeam }),
|
|
2635
|
-
},
|
|
2658
|
+
input,
|
|
2636
2659
|
{ rig: rigcRunner(bin), check: rigcRunner(bin), checkBin: bin, scratch: join(scratch, 'gate') },
|
|
2637
2660
|
console.log,
|
|
2638
2661
|
);
|
package/docs/AUTHORING.md
CHANGED
|
@@ -2500,6 +2500,18 @@ depth sheet or generated key, and adds no winding validator. Lattice meshes,
|
|
|
2500
2500
|
head turns, unrelated animations and attachments absent from the generated
|
|
2501
2501
|
body-turn deform get no contour/body-turn advice.
|
|
2502
2502
|
|
|
2503
|
+
**When a band width reverses a triangle (issue #1606).** A region's band `width` decides which
|
|
2504
|
+
outline and ring samples survive meshing, so two neighbouring widths can produce different
|
|
2505
|
+
triangulations of the same part. At some widths the triangulation leaves a sliver near the band
|
|
2506
|
+
cutoff, made of a persistent outline vertex and two ring samples with zero region share, and
|
|
2507
|
+
rigc reverses it at the body-turn extreme. On two public synthetic fixtures, width 14 refused
|
|
2508
|
+
(one triangle, 154.835 → −18.061 px²) while widths 13 and 15 built clean, and width 25 refused
|
|
2509
|
+
(13.556 → −1.985 px²) while 24 and 26 built clean, all at −15° on `body_turn` key 0. The field
|
|
2510
|
+
has no monotone direction: on both fixtures the narrower and the wider neighbour each cleared
|
|
2511
|
+
the refusal. When `RIG_CONTOUR_BODY_TURN_WINDING` names a contour mesh whose band width you just
|
|
2512
|
+
changed, try the widths on either side through the stock gate before you change any other
|
|
2513
|
+
field.
|
|
2514
|
+
|
|
2503
2515
|
**Weights.** The nominal share `g` is 1 inside or on the region, `1 − d/band` at a
|
|
2504
2516
|
distance `0 < d < band`, and 0 at or past the outer edge. With `band: 0`, the share
|
|
2505
2517
|
steps directly from 1 to 0. The endpoints are decided exactly on the 1/256 px grid.
|
|
@@ -6695,7 +6707,7 @@ recorded transform. The record fields and sampling formula are specified in
|
|
|
6695
6707
|
| <a id="RIG_EXPLICIT_ISLAND_COUNT"></a>`RIG_EXPLICIT_ISLAND_COUNT` | `explicit.islands.length` differs from the non-dust 4-connected art island count of `parts/<part>.png`; the missing or extra `<part>__island<N>` slot names and island pixel counts are named | supply one `explicit.islands` entry per non-dust art island (`<part>`, `<part>__island2`, …); nothing is written |
|
|
6696
6708
|
| <a id="RIG_EXPLICIT_ALTERNATE"></a>`RIG_EXPLICIT_ALTERNATE` | an alternate set replaces a part bound to one accepted explicit payload | use a generated mesh for alternate artwork; no alternate is inferred from a base payload |
|
|
6697
6709
|
| <a id="RIG_INFLUENCE_REACH"></a>`RIG_INFLUENCE_REACH` | an influence mesh's `radius` is at or under the distance from its farthest lattice vertex to that vertex's nearest link (issue #378): a link pulls only when it is nearer than `radius`, so that vertex would be pulled by none. The vertex, where it is and the distance are named | a `radius` above the distance named, or a segment nearer that part of the art |
|
|
6698
|
-
| <a id="RIG_CONTOUR_BODY_TURN_WINDING"></a>`RIG_CONTOUR_BODY_TURN_WINDING` | config context appended inside `RIG_RIGC_GREEN` only for rigc's actual `A39_DEFORM_KEEPS_TRIANGLE_WINDING` failure on a contour mesh attachment in the `body_turn` generated by `config.turn.body` (issue #1306). Names the part, slot/attachment, failure frame, key index/time or bounding keys/measured span time, reversal count, and rigc's shown triangle indices, vertex triples and signed before/after areas; repeated gate lines get one added line per failure frame. Rigc's original text is retained | inspect `meshes.<part>.contour.maxEdge`, `meshes.<part>.contour.margin`, `meshes.<part>.contour.tolerance` and the part's depth sheet together. The outcome is not monotone in any field; no single field is a promised fix. Only rerunning rigc's gate decides whether the candidate passes; the diagnostic changes no mesh, depth or generated key and adds no validator |
|
|
6710
|
+
| <a id="RIG_CONTOUR_BODY_TURN_WINDING"></a>`RIG_CONTOUR_BODY_TURN_WINDING` | config context appended inside `RIG_RIGC_GREEN` only for rigc's actual `A39_DEFORM_KEEPS_TRIANGLE_WINDING` failure on a contour mesh attachment in the `body_turn` generated by `config.turn.body` (issue #1306). Names the part, slot/attachment, failure frame, key index/time or bounding keys/measured span time, reversal count, and rigc's shown triangle indices, vertex triples and signed before/after areas; repeated gate lines get one added line per failure frame. Rigc's original text is retained | inspect `meshes.<part>.contour.maxEdge`, `meshes.<part>.contour.margin`, `meshes.<part>.contour.tolerance` and the part's depth sheet together. The outcome is not monotone in any field; no single field is a promised fix. When the reversal follows a change of a region's band `width`, try the widths on either side first: the width decides which outline and ring samples survive meshing, and has no monotone direction (issue #1606). Only rerunning rigc's gate decides whether the candidate passes; the diagnostic changes no mesh, depth or generated key and adds no validator |
|
|
6699
6711
|
| <a id="RIG_INFLUENCE_LATTICE"></a>`RIG_INFLUENCE_LATTICE` | rig-c's segments lattice refused the part at the declared `cell` (no pixel of the part holds art, or the cell is not a whole number of at least 1); rig-c's message is quoted | a part with art, or a whole `cell` of at least 1 |
|
|
6700
6712
|
| <a id="RIG_RIGC_GREEN"></a>`RIG_RIGC_GREEN` | rig-c refused the rig; its own FAIL or compile-error line is quoted, and nothing was written. A `constraints` field rigc does not read, or a value it refuses, is this line in rigc's words (`constraint "aim" (ik) has a key this compiler does not read: "mixx" (did you mean "mix"?)`), as is `A25_DETACHED_BONE_PARENTAGE` on a declared scene target. So is an ik whose `bones` are more than two, or two of which the second is not the first's child: from rig-c 2.15.0 its rig-spec parser refuses both by name (`ik constraint "reach" names 3 bones …`, `ik constraint "reach": "hem1" is not a child of "body" ("hem0" stands between) …`; firejune/rigc#1205), and this package no longer refuses them itself (issue #103; it did from #92 while rigc's gate passed them). Under `--idle-keys ctl` a two-bone ik over a chain link and its child link is that second refusal too, because the child's `<link>_ctl` stands between them; rigc's remedy names the control, which a config cannot, so when rigc's line says that control alone stands between, the rig stage adds a sentence naming `--idle-keys direct` on the command that ran | the field rigc's line names; for the split pair, `rig --idle-keys direct` or `build --idle-keys direct`, as the line says, which keys the link in place — rig-c's own AUTHORING §5 maps each of its assertions (`node_modules/@rig-c/core/docs/AUTHORING.md`) |
|
|
6701
6713
|
|
|
@@ -7008,7 +7020,7 @@ outside the consumed inputs.
|
|
|
7008
7020
|
| Below-floor cloth travel (unmeasured) | a link's larger unrounded carrier-frame root/tip travel is below the unchanged 0.5 rig px floor, after the zero guard. The diagnostic gives actual root and tip travel in rig px, the 0.5 rig px floor, and `measured_driver`: the nearest world-moving bone (including the carrier), `"none"` when measured still, or `"unavailable"` for missing or unusable geometry. This observes movement, not causal key attribution. The reading stays UNMEASURED under the existing SKIP policy; a separately declared requirement for measurable movement is not satisfied | drive the carrier so the cloth has measurable motion, or remove the requirement for this cloth to move on idle if that motion is not required |
|
|
7009
7021
|
| <a id="CHECK_TIP_OVER_ROOT"></a>`CHECK_TIP_OVER_ROOT` | a `handwear`/`bottomwear` part's art in the lower half of its box travels less than 1.4725 times as far as in the upper half, measured from the idle's posed geometry against the bone the part hangs from (issue #987; rig px quoted, the world reading beside it) | the chain track's `amps` (grow toward the tip), or the mesh's `segments` (the chain must be among them), or its mode: on `scarf`'s short skirt the proposal's lattice read 1.207 and the same part in `contour` mode 1.738 with the same segments and idle (issue #118) — both carried the `chest` segment #262 removed, after which the lattice reads 3.487. When the detail says `the root travels with the breath (x px of y px): it is carried by \`<bone>\`` (issue #262) the chain is not the cause: a bone an idle `translate` track moves (the breath) moves the root more than the tip, and with that translate held still (the part posed again without it, in proportion to each vertex's weight on the bone and those under it) the ratio passes — the row adds `carried_by`, `breath_rig_px`, `root_without_breath_rig_px` and `tip_without_breath_rig_px`; take that bone's segment off the mesh, or bind the root to the bone the part hangs from, which the detail names. Since issue #987 only a breath keyed under that bone is read: one at or above it is in the frame the halves are read in and carries nothing. When the bone named is a link of the chain the part hangs on, its segment stays, and the detail says to key the translate on the bone the part hangs from or above it. `nothing in it moves against \`<bone>\`` is a part that rides the bone it hangs from whole — a rigid sleeve, whose world ratio is 1. Since issue #995 a lone swing counts as a link too — a rotate-keyed bone with no child bone, or whose only child is its control twin (a one-link chain's control) — so a skirt bound to the one bone that swings it is read against the bone above, where its swing shows. A rotate-keyed body segment other bones hang under (a pelvis carrying the legs) is not one: a part bound whole to it reads `nothing in it moves against` that bone and fails, its world ratio passing only through the lever arm. Hang swinging cloth on its own bone under the body segment; a fitted garment the rig holds rigid on purpose (shorts on the pelvis) is declared in the scene file's `not_swinging` (§7), and the line then reads it SKIP with the reason. A part the scene file declares `rests` (issue #245) is held the other way, its tip half's travel at most its root half's (ratio ≤ 1); the detail then reads `the scene file's rests declares its tip at rest, so a ratio <= 1 is required`, and for it the fix is the chain's `amps` (shrinking toward the tip) or the mesh's tip weighted to a bone the idle does not swing |
|
|
7010
7022
|
| <a id="CHECK_STILL_REGIONS_DARK"></a>`CHECK_STILL_REGIONS_DARK` | a slot of the face's still set (the `face` slots and every slot drawn over the face that the head bone alone carries) moves relative to the bone the face's slot rides, or a `footwear` slot moves on the screen, by more than the arithmetic's own rounding — measured from the idle's posed geometry (the slot, its largest displacement in rig px, the idle frame and the tolerance quoted) | on the face: a face mesh with a weight on a bone other than the head (`segments`), or one deformed by another bone; on the feet: a mesh weighted to a swinging bone, or a region on the wrong bone. A bang swinging over the face is not this line's failure: its depth is reported (`crossing`), with no bar |
|
|
7011
|
-
| <a id="CHECK_TEXTURE_STRETCH"></a>`CHECK_TEXTURE_STRETCH` | a mesh triangle's edge, in some idle frame, is more than 1.926544 times its rest length or less than 1/1.926544 of it (the mesh, triangle, its three vertices, the edge and the frame are named, and — issue #314 — the bones the edge's two vertices hang on: each vertex's two largest weights from `rig.json`, `vertex <i> is weighted to "<bone>" <w>, …`, then `on the idle's chains, the chain from "<first link>" carries "<bone>", …` — each chain `CHAIN_LAG` reads named once, by its first link — with a bone on no chain said, or `none of these bones hangs on a chain of the idle`); or a rest edge has length 0 A differing bone set on the failing edge or triangle names the bone and both shares. Cut attribution requires a matching config replay; otherwise the influence-cut remedy is conditional ("The weight cut"). | the chain tracks' `amps` on the bones that mesh is weighted to (the stretch grows with them), or the mesh's `segments` — a vertex blending two bones that swing against each other. Two chains named, with opposed amplitudes: give both one sign, or drop one — `propose --from-config` measures the pair before a build (§3, *Two chains on one lattice*). An edge whose two ends disagree on whether a bone's small share survives the 0.03 cut (one vertex keeps the bone at a few hundredths, the next drops it — read the two vertices' weights the line quotes): declare `influences: {floor: "continuous"}` on that mesh first, `rule: "heat"` second; the weight `exponent` moves the figure without removing the cut (issue #115, `reference-demo` `hair_back` as contour at tolerance 1, rig-c 2.47.1: 2.535 as drafted; continuous floor 1.422, heat 1.816, both PASS; exponent 1.5 / 3 / 4 / 6 read 2.564 / 1.902 / 2.119 / 4.816, the one pass on the same cut at another edge) |
|
|
7023
|
+
| <a id="CHECK_TEXTURE_STRETCH"></a>`CHECK_TEXTURE_STRETCH` | a mesh triangle's edge, in some idle frame, is more than 1.926544 times its rest length or less than 1/1.926544 of it (the mesh, triangle, its three vertices, the edge and the frame are named, and — issue #314 — the bones the edge's two vertices hang on: each vertex's two largest weights from `rig.json`, `vertex <i> is weighted to "<bone>" <w>, …`, then `on the idle's chains, the chain from "<first link>" carries "<bone>", …` — each chain `CHAIN_LAG` reads named once, by its first link — with a bone on no chain said, or `none of these bones hangs on a chain of the idle`); or a rest edge has length 0 A differing bone set on the failing edge or triangle names the bone and both shares. Cut attribution requires a matching config replay; otherwise the influence-cut remedy is conditional ("The weight cut"). When a vertex of the failing edge lies inside a declared contour band or at its cutoff, the detail also names the governing contour band — its region, its target bone, its declared width (`band`), and each vertex's band position and share — and says that the band's falloff governs the edge (issue #1598). The clause needs the config: on `build`, the one it ran with; on a standalone `check --rig`, the one `<rig>/run.json` (`rig-run/1`, from `rig`) names, used only when the stamp's `rig.json` and config SHA-256 both match the files on disk. Without a verified config, or when an edge vertex does not rebuild onto the contour grid, the clause is left out and the rest of the line is unchanged. | the chain tracks' `amps` on the bones that mesh is weighted to (the stretch grows with them), or the mesh's `segments` — a vertex blending two bones that swing against each other. Two chains named, with opposed amplitudes: give both one sign, or drop one — `propose --from-config` measures the pair before a build (§3, *Two chains on one lattice*). An edge whose two ends disagree on whether a bone's small share survives the 0.03 cut (one vertex keeps the bone at a few hundredths, the next drops it — read the two vertices' weights the line quotes): declare `influences: {floor: "continuous"}` on that mesh first, `rule: "heat"` second; the weight `exponent` moves the figure without removing the cut (issue #115, `reference-demo` `hair_back` as contour at tolerance 1, rig-c 2.47.1: 2.535 as drafted; continuous floor 1.422, heat 1.816, both PASS; exponent 1.5 / 3 / 4 / 6 read 2.564 / 1.902 / 2.119 / 4.816, the one pass on the same cut at another edge). When the detail names a governing contour band (an edge with a vertex inside a declared contour band or at its cutoff), go to that band's width (`meshes.<part>.contour.regions[].band`, or `meshes.<part>.contour.bust` for a derived bust band), not `meshes.<part>.influences` or mesh density: the reach is not monotonic in the band's width, so sweep it on your own rig and read both yaw directions |
|
|
7012
7024
|
| <a id="CHECK_ANIMATIONS_DO_NOT_FOLD"></a>`CHECK_ANIMATIONS_DO_NOT_FOLD` | an animation, the idle included, turns a mesh triangle over against the setup pose on some frame, read by `rigc render --folds` over the build with its physics on — and with its physics constraints left out beside it when the rig declares any, so each row reports `physics_on` and `physics_off` side by side (issues #320, #333, #363); the object names the animation and the mesh, the detail quotes rigc's line — the frames, the worst frame, which triangles, their world box and setup-pose area — and when the fold appears only with physics on, names the physics constraint(s) on the mesh's bones and the worst frame. After rigc's line it names what the worst frame's folded triangles hang on (issue #567), in `TEXTURE_STRETCH`'s words: each vertex's dominant bone is its largest weight in `rig.json`, the triangles whose vertices share one set of dominant bones are one group (the set in `rig.json`'s bone order), and each group lists its first 6 triangles (`triangles 63, 78, 79 dominated by "knee_r", "knee_l"`, past 6 `… and N more`) and spells out its first triangle's vertices — the largest two weights of each, and the idle chains those bones hang on; 3 groups are written and the rest counted (`; … and N more group(s), M triangle(s)`). An attachment the skin does not hold, or a triangle its table does not reach, is said, not guessed. Or a `may_fold` entry of the `--requirements` file names a slot and animation that does not fold: an exception that excepts nothing A differing bone set on the failing edge or triangle names the bone and both shares. Cut attribution requires a matching config replay; otherwise the influence-cut remedy is conditional ("The weight cut"). | the physics constraint(s) the line names (lower `inertia`, raise `strength`, or lower `damping`), the clip's keys on the bones the line names (a bend past what the weights carry, two bones turned toward each other until the rows between them pass, a translate that carries one row of vertices past the next), or the mesh's `segments`; to look, `rigc inspect --candidate <out>/check/build --show art,folds,mesh --animation <name> --at <the worst frame's time> --zoom folds`. A fold the art means (a sleeve behind the body) is declared, `"may_fold": [{ "slot": …, "animation": …, "why": … }]` (§7, *Declared requirements*); a stale entry is taken out |
|
|
7013
7025
|
| <a id="CHECK_FEET_STAY_LEVEL"></a>`CHECK_FEET_STAY_LEVEL` | a `footwear` part riding a bone that hangs from another turns more than ±10 degrees from its setup pose on a frame where a bone above that bone is turned (issue #348) — the bar is HQ's line (rig-c/parts#347 ruling 4), not a figure measured here; the object names the part, its bone and the bone it hangs from, the detail the animation, frame and time, the turned bone and its turn, the drawing's turn, and every bone the turn came through with its `inherit` | config.bones' `inherit` on the foot's bone (§3, `bones`): a mode that does not take the parent's rotation (`noRotationOrReflection`, `onlyTranslation`) keeps the drawing at its setup angle; which mode is the author's. Or the clip's keys on the foot's own bone, which turn the shoe whatever its mode |
|
|
7014
7026
|
| <a id="CHECK_STRESS_OFF_CHAIN"></a>`CHECK_STRESS_OFF_CHAIN` | a mesh from a See-through `handwear` layer that rides one chain of the idle does not turn rigidly with it: with the chain's first link turned 90°, −90° or 180° on a throwaway copy (physics left out, posed by rigc, issue #347), its worst edge reads above 1.0000 as max(ratio, 1/ratio) against the setup pose. The object names the mesh, the link and the turn; the detail quotes the edge and names each bone the mesh is weighted to off the chain, with how many vertices carry it and the largest weight. Or the turned render shows no mesh on the slot: not read is not a pass | the mesh's `segments`: drop the segment on the bone the line names (a 16 px `chest` stub at the shoulder, as `propose` drafted until issue #347), so the sleeve rides its chain alone. Measured (rigc 2.47.1): `demo`'s sleeves read 2.46 to 254.7 with the stub and 1.0000 without it, and the setup-pose seam does not move (mean 0.147, 0 px over 40, both ways) |
|
|
@@ -7242,6 +7254,7 @@ and stay absent).
|
|
|
7242
7254
|
| <a id="SCENE_INVARIANT_AGREES"></a>`SCENE_INVARIANT_AGREES` | two characters declare `invariants.idleDrivesMeshes` with different `why`s | rebuild with this package's `--idle-keys direct`, whose `why` is one sentence |
|
|
7243
7255
|
| <a id="SCENE_IMAGE_NAME_FREE"></a>`SCENE_IMAGE_NAME_FREE` | two images compose to one file name (`<id>.<file>`: an id `x` with an image `y.cloth.png`, and an id `x.y` with `cloth.png`) | another id |
|
|
7244
7256
|
| <a id="COMPOSE_RIGC_GREEN"></a>`COMPOSE_RIGC_GREEN` | rig-c refused the composed rig; its line is quoted. A field compose carries as written (a constraint's `mix`, a slot's setup attachment) is rigc's to judge | the build whose field it names |
|
|
7257
|
+
| <a id="COMPOSE_PREVIEW_REQUIRED_CHECK"></a>`COMPOSE_PREVIEW_REQUIRED_CHECK` | `--loop-seam-bar` with `--output-profile preview`. The `loop_seam` record in `check.json` binds the paths and SHA-256 hashes of the first and wrap PNGs under `check/idle_frames/`, which preview removes | `found=preview, required=default or no-extremes`. Use default diagnostics or `--no-extremes` to retain the bound PNGs |
|
|
7245
7258
|
| `REQUIREMENTS_*` | the `--requirements` file, as for `check` | as for `check` |
|
|
7246
7259
|
|
|
7247
7260
|
### The command line
|
|
@@ -7481,7 +7494,7 @@ assemble*, at the end of this section):
|
|
|
7481
7494
|
|
|
7482
7495
|
**Physics-on idle closure (opt-in, issue #1590).** Pass
|
|
7483
7496
|
`--loop-seam-bar <channel-delta,pixels> --loop-seam-cap <loops>` together to
|
|
7484
|
-
`check` or `compose
|
|
7497
|
+
`check` or `compose` (default diagnostics or `--no-extremes`). Use decimal whole numbers: a channel delta from 0 to 255,
|
|
7485
7498
|
a nonnegative safe integer pixel limit, and a nonnegative safe integer warm-up
|
|
7486
7499
|
cap. The rig must have an idle of positive duration. Core's warm-up search is
|
|
7487
7500
|
incompatible with `check --environment`.
|
|
@@ -8029,12 +8042,12 @@ rig directory, copied away from its `parts.json`, reads `5 of 10`: the gate, the
|
|
|
8029
8042
|
|
|
8030
8043
|
### Composing several characters (`compose`, issue #74)
|
|
8031
8044
|
|
|
8032
|
-
`rig-parts compose --scene <scene.json> --out <dir> [--requirements <file.json>] [--accept <bar>[,<bar>…]] [--page-size <px>] [--loop-seam-bar <channel-delta,pixels> --loop-seam-cap <loops>]`
|
|
8045
|
+
`rig-parts compose --scene <scene.json> --out <dir> [--requirements <file.json>] [--accept <bar>[,<bar>…]] [--page-size <px>] [--loop-seam-bar <channel-delta,pixels> --loop-seam-cap <loops>] [--output-profile preview] [--no-extremes]`
|
|
8033
8046
|
binds characters this package already built into one rig. Each character runs the
|
|
8034
8047
|
single-character path (§4, steps 0–9) on its own, already isolated input to a green
|
|
8035
8048
|
`build` first; compose reads what that build wrote and changes nothing in it.
|
|
8036
|
-
|
|
8037
|
-
the
|
|
8049
|
+
With default diagnostics or `--no-extremes`, the paired loop seam flags apply to
|
|
8050
|
+
the composed idle under `<out>/check/`, at the viewport used for the shipped frames.
|
|
8038
8051
|
|
|
8039
8052
|
```
|
|
8040
8053
|
{ "spec": "spine-parts-scene/1",
|
|
@@ -8351,6 +8364,36 @@ character's input arrives isolated); a composed `parts.json`, so the bars that
|
|
|
8351
8364
|
read See-through tags are measured per character by its own `build`, not over the
|
|
8352
8365
|
scene; a rig `build` did not write.
|
|
8353
8366
|
|
|
8367
|
+
#### Compose output profiles (issue #1610)
|
|
8368
|
+
|
|
8369
|
+
| Options | Omitted diagnostics under `<out>/check/` | Successful terminal verdict | `compose-run.json` `output_profile` |
|
|
8370
|
+
| --- | --- | --- | --- |
|
|
8371
|
+
| Neither flag | None selected for omission | `compose: PASS — …` | absent |
|
|
8372
|
+
| `--no-extremes` alone | `extremes/`, as in `check` and `build` | `compose: NO EXTREMES — checks met; …` | `"no-extremes"` |
|
|
8373
|
+
| `--output-profile preview`, with or without `--no-extremes` | `extremes/`, `idle_frames/`, `contact.png`, `motion_heat.png` | `compose: PREVIEW — checks met; …` | `"preview"` |
|
|
8374
|
+
|
|
8375
|
+
Preview uses Core's stock idle renderer and the existing readers for its
|
|
8376
|
+
frames and geometry. With any `canvas_clip: true` character, that render uses
|
|
8377
|
+
the authored stage viewport. Core generates a contact sheet alongside the
|
|
8378
|
+
temporary idle frames. Parts removes the idle render directory before preview
|
|
8379
|
+
success, skips copying the contact sheet to `check/contact.png`, and skips
|
|
8380
|
+
generating `check/motion_heat.png`. The rig-c gate, packed build, camera binding
|
|
8381
|
+
and check requirements still apply. The `[check]` diagnostics
|
|
8382
|
+
lines give the chosen flag as the reason for `extremes: SKIP` and, in preview,
|
|
8383
|
+
`idle diagnostics: SKIP`. These lines describe output omissions. Each bar and
|
|
8384
|
+
requirement retains its own outcome. Failed checks and accepted failing input
|
|
8385
|
+
bars still exit 1 and leave no compose receipt.
|
|
8386
|
+
|
|
8387
|
+
`preview` is the only accepted value for `--output-profile`. A valid pair of
|
|
8388
|
+
`--loop-seam-bar` and `--loop-seam-cap` in preview exits 1 with
|
|
8389
|
+
`COMPOSE_PREVIEW_REQUIRED_CHECK` (`found=preview, required=default or no-extremes`).
|
|
8390
|
+
The declared physics-on seam check embeds Core's `loop_seam` evidence in
|
|
8391
|
+
`check.json`. Its `first` and `wrap` entries bind the relative paths and SHA-256
|
|
8392
|
+
hashes of `f0000.png` and `loop-wrap.png` under the idle render directory.
|
|
8393
|
+
Both files must remain under `check/idle_frames/` for readers to verify the
|
|
8394
|
+
seam evidence after the run. This refusal clears `rig/`, `check/`, `scene.json` and
|
|
8395
|
+
`compose-run.json` under `--out` before the gate.
|
|
8396
|
+
|
|
8354
8397
|
#### Keyed scene camera (issue #1596)
|
|
8355
8398
|
|
|
8356
8399
|
A camera projects an already posed scene into the fixed canvas. It follows the
|
|
@@ -8459,11 +8502,12 @@ The rig-c gate, composed rig and packed atlas retain the full art, geometry and
|
|
|
8459
8502
|
motion so offstage parts can enter the canvas during playback.
|
|
8460
8503
|
|
|
8461
8504
|
When any character opts in, compose gives check renders the authored stage as
|
|
8462
|
-
their viewport
|
|
8505
|
+
their viewport, including the temporary stock idle render in preview. Explicit
|
|
8506
|
+
diagnostic viewports take precedence. With default diagnostics or `--no-extremes`, the retained
|
|
8463
8507
|
`check/idle_frames/` and `check/contact.png` use check's existing preview size
|
|
8464
8508
|
cap and sampling rate. `check/idle_frames/frames.json` records the stage in
|
|
8465
|
-
`viewport` and identifies the pin in `pinned.by` as `--viewport`.
|
|
8466
|
-
their
|
|
8509
|
+
`viewport` and identifies the pin in `pinned.by` as `--viewport`. The default
|
|
8510
|
+
extremes use their explicit diagnostic grid over the same stage box.
|
|
8467
8511
|
The stage rectangle is `[-width/2, 0, width, height]` in rig-c world coordinates,
|
|
8468
8512
|
y up. To verify native canvas pixels, render the packed build with the stage
|
|
8469
8513
|
rectangle as `--viewport` and the larger canvas dimension as `--max`.
|
|
@@ -8483,12 +8527,13 @@ every character in the declared draw order.
|
|
|
8483
8527
|
A fully green compose writes `compose-run.json` at the `--out` root, beside
|
|
8484
8528
|
`scene.json`, with spec `rig-compose-run/1`. It removes a previous record before
|
|
8485
8529
|
the stage begins, including before stage option validation; a refused input,
|
|
8486
|
-
rig-c gate, check or accepted failing character leaves no record. With
|
|
8487
|
-
canvas clipping nor a placement pivot declared, the
|
|
8488
|
-
and check bytes and paths are stable. Core's separate
|
|
8489
|
-
retains its own clocks.
|
|
8530
|
+
rig-c gate, check or accepted failing character leaves no record. With default
|
|
8531
|
+
diagnostics and neither canvas clipping nor a placement pivot declared, the
|
|
8532
|
+
existing rig, scene report and check bytes and paths are stable. Core's separate
|
|
8533
|
+
`check/build/run.json` retains its own clocks.
|
|
8490
8534
|
|
|
8491
|
-
The fixed top-level key order is `spec`, `scene`, `characters`, `plate`, `plates
|
|
8535
|
+
The fixed top-level key order is `spec`, `scene`, `characters`, `plate`, `plates`,
|
|
8536
|
+
then `output_profile` when selected.
|
|
8492
8537
|
|
|
8493
8538
|
| entry | exact binding |
|
|
8494
8539
|
| --- | --- |
|
|
@@ -8496,6 +8541,7 @@ The fixed top-level key order is `spec`, `scene`, `characters`, `plate`, `plates
|
|
|
8496
8541
|
| `characters` | sorted by `id` in code-unit order. Each row has `id`, `build`, `files`, then `placement` only for `canvas_clip: true`. `build` is as declared and `files` contains `{path, sha256}` entries sorted by build-relative `path`. `placement` holds `{canvas_clip: true, bounds, clipped_bounds}` from the scene report |
|
|
8497
8542
|
| `plate` | legacy plate `{path, sha256}`, with its image path as declared relative to the scene file, or `null` when absent |
|
|
8498
8543
|
| `plates` | every named plate `{name, path, sha256}`, sorted by `name` in code-unit order; image paths as declared relative to the scene file; `[]` when absent |
|
|
8544
|
+
| `output_profile` | `"preview"` for `--output-profile preview`, including when paired with `--no-extremes`; `"no-extremes"` for `--no-extremes` alone; absent for default diagnostics |
|
|
8499
8545
|
|
|
8500
8546
|
The raw `scene.sha256` binds the placement pivot declaration and its authored
|
|
8501
8547
|
tracks. A pivot adds no receipt field. The `placement` entry retains its canvas
|
|
@@ -8510,13 +8556,14 @@ It does not enumerate the build directory: unused images, packed pages,
|
|
|
8510
8556
|
source configs and the character's own `run.json` are excluded. A declared
|
|
8511
8557
|
`parts.json` painting binding and editor receipts keep their existing validation;
|
|
8512
8558
|
their declarations are bound through the containing input bytes. This record
|
|
8513
|
-
inventories the listed compose inputs
|
|
8559
|
+
inventories the listed compose inputs and the selected output profile. External
|
|
8560
|
+
requirements and other CLI options are outside its inventory.
|
|
8514
8561
|
|
|
8515
8562
|
Hashes are captured from the same byte buffers consumed before the gate, never
|
|
8516
8563
|
by rereading inputs after it. Image hashes bind encoded file bytes, including
|
|
8517
8564
|
any trailing bytes, rather than decoded pixels. Identical inputs at identical
|
|
8518
|
-
supplied paths give identical record bytes
|
|
8519
|
-
changes its input entry's hash
|
|
8565
|
+
supplied paths with the same output profile give identical record bytes. A changed
|
|
8566
|
+
byte changes its input entry's hash. If multiple entries reference one physical file,
|
|
8520
8567
|
each reference changes. Missing scene, build and plate files retain their named
|
|
8521
8568
|
`SCENE_FILE`, `SCENE_BUILD_PRESENT` and `SCENE_PLATE_PRESENT` refusals.
|
|
8522
8569
|
|
|
@@ -10757,8 +10804,8 @@ Internal `SeamSupport.drawings` never enters check JSON. Named requirement
|
|
|
10757
10804
|
<!-- check-row-table:begin -->
|
|
10758
10805
|
| Row family | Registered JSON paths | row_scope | row_kind | row_subjects (producer expression) | Producer |
|
|
10759
10806
|
| --- | --- | --- | --- | --- | --- |
|
|
10760
|
-
| `ANIMATIONS_DO_NOT_FOLD.declared_not_folding` | `ANIMATIONS_DO_NOT_FOLD.declared_not_folding` | part when the supplied mapping resolves a piece; otherwise rig | finding | resolved piece for e.slot; otherwise [] | [check.ts:
|
|
10761
|
-
| `ANIMATIONS_DO_NOT_FOLD.folding` | `ANIMATIONS_DO_NOT_FOLD.folding` | part when the supplied mapping resolves a piece; otherwise rig | finding when entry === undefined; otherwise evidence | resolved piece for slot; otherwise [] | [check.ts:
|
|
10807
|
+
| `ANIMATIONS_DO_NOT_FOLD.declared_not_folding` | `ANIMATIONS_DO_NOT_FOLD.declared_not_folding` | part when the supplied mapping resolves a piece; otherwise rig | finding | resolved piece for e.slot; otherwise [] | [check.ts:3876](../src/check.ts#L3876) |
|
|
10808
|
+
| `ANIMATIONS_DO_NOT_FOLD.folding` | `ANIMATIONS_DO_NOT_FOLD.folding` | part when the supplied mapping resolves a piece; otherwise rig | finding when entry === undefined; otherwise evidence | resolved piece for slot; otherwise [] | [check.ts:3836](../src/check.ts#L3836) |
|
|
10762
10809
|
| `ART_JOINT_DISTANCE.joints` | `ART_JOINT_DISTANCE.joints` | 'rig' | finding when status === 'FAIL'; otherwise evidence | [] | [artjoints.ts:86](../src/artjoints.ts#L86) |
|
|
10763
10810
|
| `BEHIND_PART_SEAMS.contributors` | `BEHIND_PART_SEAMS.turn.pairs[].frames[].standing.samples[].contributors`; `BEHIND_PART_SEAMS.turn.pairs[].frames[].motion_opened.samples[].contributors`; `BEHIND_PART_SEAMS.pairs[].setup.motion_opened.samples[].contributors`; `BEHIND_PART_SEAMS.pairs[].setup.standing.samples[].contributors`; `BEHIND_PART_SEAMS.pairs[].frames[].motion_opened.samples[].contributors`; `BEHIND_PART_SEAMS.pairs[].frames[].standing.samples[].contributors` | 'pair' | evidence | [pair.a, pair.b] | [behindseams.ts:664](../src/behindseams.ts#L664) |
|
|
10764
10811
|
| `BEHIND_PART_SEAMS.hits` | `BEHIND_PART_SEAMS.pairs[].motion_opened.frames`; `BEHIND_PART_SEAMS.pairs[].standing.frames`; `BEHIND_PART_SEAMS.pairs[].motion_opened.worst`; `BEHIND_PART_SEAMS.pairs[].standing.worst` | 'pair' | finding when r.px > allowance; otherwise evidence | parts | [behindseams.ts:750](../src/behindseams.ts#L750) |
|
|
@@ -10774,53 +10821,53 @@ Internal `SeamSupport.drawings` never enters check JSON. Named requirement
|
|
|
10774
10821
|
| `BEHIND_PART_SEAMS.unread_corridors` | `BEHIND_PART_SEAMS.turn.pairs[].frames[].standing.unread_corridors`; `BEHIND_PART_SEAMS.pairs[].setup.standing.unread_corridors`; `BEHIND_PART_SEAMS.pairs[].frames[].standing.unread_corridors` | 'pair' | evidence | [pair.a, pair.b] | [behindseams.ts:585](../src/behindseams.ts#L585) |
|
|
10775
10822
|
| `BOUNDARY_COLOUR_STEP.over` | `BOUNDARY_COLOUR_STEP.over` | 'pair' | finding | r.parts | [boundarycolour.ts:221](../src/boundarycolour.ts#L221) |
|
|
10776
10823
|
| `BOUNDARY_COLOUR_STEP.unmeasured` | `BOUNDARY_COLOUR_STEP.unmeasured` | part when the supplied mapping resolves a piece; otherwise rig | evidence | resolved piece for r.slot; otherwise [] | [boundarycolour.ts:222](../src/boundarycolour.ts#L222) |
|
|
10777
|
-
| `CLOTH_SETTLES.rows` | `CLOTH_SETTLES.rows` | 'rig' | finding when speeds.length > 0 && s < speeds.length; otherwise evidence | [] | [check.ts:
|
|
10824
|
+
| `CLOTH_SETTLES.rows` | `CLOTH_SETTLES.rows` | 'rig' | finding when speeds.length > 0 && s < speeds.length; otherwise evidence | [] | [check.ts:6329](../src/check.ts#L6329) |
|
|
10778
10825
|
| `CUT_JOINT_MATERIAL.rows` | `CUT_JOINT_MATERIAL.rows` | 'part' | finding when r.status === 'FAIL'; otherwise evidence | [r.part] | [cutmaterial.ts:280](../src/cutmaterial.ts#L280) |
|
|
10779
|
-
| `FEET_STAY_LEVEL.feet` | `FEET_STAY_LEVEL.feet` | 'part' | finding when row.status === 'FAIL'; otherwise evidence | [row.part] | [check.ts:
|
|
10780
|
-
| `FEET_STAY_LEVEL.feet[].worst.through` | `FEET_STAY_LEVEL.feet[].worst.through` | 'rig' | evidence | [] | [check.ts:
|
|
10781
|
-
| `LIMB_ONE_BONE.parts` | `LIMB_ONE_BONE.parts` | 'part' | finding when fail; otherwise evidence | [p.name] | [check.ts:
|
|
10826
|
+
| `FEET_STAY_LEVEL.feet` | `FEET_STAY_LEVEL.feet` | 'part' | finding when row.status === 'FAIL'; otherwise evidence | [row.part] | [check.ts:4078](../src/check.ts#L4078) |
|
|
10827
|
+
| `FEET_STAY_LEVEL.feet[].worst.through` | `FEET_STAY_LEVEL.feet[].worst.through` | 'rig' | evidence | [] | [check.ts:4053](../src/check.ts#L4053) |
|
|
10828
|
+
| `LIMB_ONE_BONE.parts` | `LIMB_ONE_BONE.parts` | 'part' | finding when fail; otherwise evidence | [p.name] | [check.ts:4371](../src/check.ts#L4371) |
|
|
10782
10829
|
| `PART_SUPPORT_REPORT.pairs` | `PART_SUPPORT_REPORT.pairs` | 'pair' | evidence; finding when length > 0; otherwise evidence | [F.name, B.name] | [coincide.ts:114](../src/coincide.ts#L114), [coincide.ts:130](../src/coincide.ts#L130) |
|
|
10783
10830
|
| `PART_SUPPORT_REPORT.raw_pairs` | `PART_SUPPORT_REPORT.raw_pairs` | 'pair' | evidence | [F.name, B.name] | [coincide.ts:110](../src/coincide.ts#L110) |
|
|
10784
10831
|
| `PART_SUPPORT_REPORT.unowned.regions` | `PART_SUPPORT_REPORT.unowned.regions` | 'rig' | finding | [] | [coincide.ts:145](../src/coincide.ts#L145) |
|
|
10785
10832
|
| `PHYSICS_CONTRIBUTES.rows` | `PHYSICS_CONTRIBUTES.rows` | 'part' | evidence; finding when !moves; otherwise evidence | [part] | [physicscontrib.ts:217](../src/physicscontrib.ts#L217), [physicscontrib.ts:220](../src/physicscontrib.ts#L220) |
|
|
10786
|
-
| `SEAM_OVER_MOTION.pairs` | `SEAM_OVER_MOTION.pairs` | 'pair' | evidence | [p.a, p.b] | [check.ts:
|
|
10787
|
-
| `SEAM_OVER_MOTION.required.pairs` | `SEAM_OVER_MOTION.required.pairs` | 'pair' | finding when open > 0; otherwise evidence | [p.a, p.b] | [check.ts:
|
|
10788
|
-
| `SEAM_OVER_MOTION.required.pairs[].open_frames` | `SEAM_OVER_MOTION.required.pairs[].open_frames` | 'pair' | evidence | [p.a, p.b] | [check.ts:
|
|
10789
|
-
| `SEAM_OVER_MOTION.roots.unmeasured` | `SEAM_OVER_MOTION.roots.unmeasured` | 'part' | evidence | [root.part] | [check.ts:
|
|
10790
|
-
| `SEAM_OVER_MOTION.rows` | `SEAM_OVER_MOTION.rows` | 'pair'; unique ? 'pair' : 'rig' | finding when motionSeamFinding(want.root !== undefined, p.status, p.banded, opens.length); otherwise evidence; finding when motionSeamFinding(rootNames.has(r.pair), r.status, r.banded, r.opens.length); otherwise evidence | [want.a, want.b]; unique ? [pair.a, pair.b] : [] | [check.ts:
|
|
10791
|
-
| `SEAM_OVER_MOTION.rows[].cells` | `SEAM_OVER_MOTION.rows[].cells` | 'pair' | evidence | [want.a, want.b] | [check.ts:
|
|
10792
|
-
| `SEAM_OVER_MOTION.rows[].joint_contact.reasons` | `SEAM_OVER_MOTION.rows[].joint_contact.reasons` | 'pair' | evidence | [want.a, want.b] | [check.ts:
|
|
10833
|
+
| `SEAM_OVER_MOTION.pairs` | `SEAM_OVER_MOTION.pairs` | 'pair' | evidence | [p.a, p.b] | [check.ts:5726](../src/check.ts#L5726) |
|
|
10834
|
+
| `SEAM_OVER_MOTION.required.pairs` | `SEAM_OVER_MOTION.required.pairs` | 'pair' | finding when open > 0; otherwise evidence | [p.a, p.b] | [check.ts:5041](../src/check.ts#L5041) |
|
|
10835
|
+
| `SEAM_OVER_MOTION.required.pairs[].open_frames` | `SEAM_OVER_MOTION.required.pairs[].open_frames` | 'pair' | evidence | [p.a, p.b] | [check.ts:5033](../src/check.ts#L5033) |
|
|
10836
|
+
| `SEAM_OVER_MOTION.roots.unmeasured` | `SEAM_OVER_MOTION.roots.unmeasured` | 'part' | evidence | [root.part] | [check.ts:5699](../src/check.ts#L5699) |
|
|
10837
|
+
| `SEAM_OVER_MOTION.rows` | `SEAM_OVER_MOTION.rows` | 'pair'; unique ? 'pair' : 'rig' | finding when motionSeamFinding(want.root !== undefined, p.status, p.banded, opens.length); otherwise evidence; finding when motionSeamFinding(rootNames.has(r.pair), r.status, r.banded, r.opens.length); otherwise evidence | [want.a, want.b]; unique ? [pair.a, pair.b] : [] | [check.ts:5656](../src/check.ts#L5656), [check.ts:5732](../src/check.ts#L5732) |
|
|
10838
|
+
| `SEAM_OVER_MOTION.rows[].cells` | `SEAM_OVER_MOTION.rows[].cells` | 'pair' | evidence | [want.a, want.b] | [check.ts:5669](../src/check.ts#L5669) |
|
|
10839
|
+
| `SEAM_OVER_MOTION.rows[].joint_contact.reasons` | `SEAM_OVER_MOTION.rows[].joint_contact.reasons` | 'pair' | evidence | [want.a, want.b] | [check.ts:5659](../src/check.ts#L5659) |
|
|
10793
10840
|
| `SEAM_OVER_MOTION.rows[].pose_at_worst.joints` | `SEAM_OVER_MOTION.rows[].pose_at_worst.joints` | 'rig' | evidence | [] | [motionseampose.ts:53](../src/motionseampose.ts#L53) |
|
|
10794
|
-
| `SEAM_OVER_MOTION.worlds.*.rows` | `SEAM_OVER_MOTION.worlds.*.rows` | 'pair' | evidence | [want.a, want.b] | [check.ts:
|
|
10795
|
-
| `SEAM_OVER_RANGE.joints` | `SEAM_OVER_RANGE.joints` | 'part' | evidence; finding when poses.some(p => p.status === 'FAIL'); otherwise evidence | [j.part] | [check.ts:
|
|
10796
|
-
| `SEAM_OVER_RANGE.joints[].poses` | `SEAM_OVER_RANGE.joints[].poses` | 'part' | finding when fail; otherwise evidence | [j.part] | [check.ts:
|
|
10841
|
+
| `SEAM_OVER_MOTION.worlds.*.rows` | `SEAM_OVER_MOTION.worlds.*.rows` | 'pair' | evidence | [want.a, want.b] | [check.ts:5653](../src/check.ts#L5653) |
|
|
10842
|
+
| `SEAM_OVER_RANGE.joints` | `SEAM_OVER_RANGE.joints` | 'part' | evidence; finding when poses.some(p => p.status === 'FAIL'); otherwise evidence | [j.part] | [check.ts:4695](../src/check.ts#L4695), [check.ts:4741](../src/check.ts#L4741) |
|
|
10843
|
+
| `SEAM_OVER_RANGE.joints[].poses` | `SEAM_OVER_RANGE.joints[].poses` | 'part' | finding when fail; otherwise evidence | [j.part] | [check.ts:4739](../src/check.ts#L4739) |
|
|
10797
10844
|
| `SETUP_MATCHES_PAINTING.regions` | `SETUP_MATCHES_PAINTING.regions` | 'rig' | finding when status === 'FAIL'; otherwise evidence | [] | [setuppainting.ts:175](../src/setuppainting.ts#L175) |
|
|
10798
10845
|
| `SETUP_MATCHES_PAINTING.regions[].slots` | `SETUP_MATCHES_PAINTING.regions[].slots` | part when the supplied mapping resolves a piece; otherwise rig | evidence | resolved piece for slot; otherwise [] | [setuppainting.ts:176](../src/setuppainting.ts#L176) |
|
|
10799
10846
|
| `SOURCE_EXPOSURE.rows` | `SOURCE_EXPOSURE.rows` | 'part' | finding when declared !== undefined && r.px > declared.max_px; otherwise evidence | [r.part] | [sourceexposure.ts:292](../src/sourceexposure.ts#L292) |
|
|
10800
10847
|
| `SOURCE_EXPOSURE.unmeasured` | `SOURCE_EXPOSURE.unmeasured` | part when the supplied mapping resolves a piece; otherwise rig | finding when declared !== undefined; otherwise evidence | resolved piece for u.slot; otherwise [] | [sourceexposure.ts:293](../src/sourceexposure.ts#L293) |
|
|
10801
|
-
| `STILL_REGIONS_DARK.*.crossing` | `STILL_REGIONS_DARK.*.crossing` | part when the supplied mapping resolves a piece; otherwise rig | finding | resolved piece for sl.name; otherwise [] | [check.ts:
|
|
10802
|
-
| `STILL_REGIONS_DARK.*.still_slots` | `STILL_REGIONS_DARK.*.still_slots` | part when the supplied mapping resolves a piece; otherwise rig | evidence; finding when r.max > tolerance; otherwise evidence | resolved piece for slot; otherwise [] | [check.ts:
|
|
10803
|
-
| `STRESS_OFF_CHAIN.not_read` | `STRESS_OFF_CHAIN.not_read` | 'part' | evidence | [r.part] | [check.ts:
|
|
10804
|
-
| `STRESS_OFF_CHAIN.per_part` | `STRESS_OFF_CHAIN.per_part` | 'part' | finding when poses.some(p => typeof p.reading === 'number' && p.reading > STRESS_RIGID); otherwise evidence | [r.part] | [check.ts:
|
|
10805
|
-
| `STRESS_OFF_CHAIN.per_part[].off_chain` | `STRESS_OFF_CHAIN.per_part[].off_chain` | 'part' | evidence | [r.part] | [check.ts:
|
|
10806
|
-
| `STRESS_OFF_CHAIN.per_part[].poses` | `STRESS_OFF_CHAIN.per_part[].poses` | 'part' | evidence; finding when shown > STRESS_RIGID; otherwise evidence | [r.part] | [check.ts:
|
|
10807
|
-
| `TEXTURE_STRETCH.per_mesh` | `TEXTURE_STRETCH.per_mesh` | part when the supplied mapping resolves a piece; otherwise rig | evidence; finding when severity > TEXTURE_STRETCH_CEILING; otherwise evidence | resolved piece for m.slot; otherwise [] | [check.ts:
|
|
10808
|
-
| `TIP_OVER_ROOT.parts` | `TIP_OVER_ROOT.parts` | 'part' | evidence; finding when !ok && !(!rigid && hanging.onLink && Math.max(c.root, c.tip) < TIP_TRAVEL_FLOOR); otherwise evidence | [p.name] | [check.ts:
|
|
10809
|
-
| `WIND_BAND.pairs` | `WIND_BAND.pairs` | 'pair' | finding when !holdsAll; otherwise evidence | [p.a, p.b] | [check.ts:
|
|
10810
|
-
| `WIND_BAND.pairs[].steps` | `WIND_BAND.pairs[].steps` | 'pair' | finding when !s.holds; otherwise evidence | [p.a, p.b] | [check.ts:
|
|
10811
|
-
| `figure_openings.openings` | `figure_openings.openings` | 'pair' | finding | [ps.under, ps.above] | [check.ts:
|
|
10812
|
-
| `loop_physics` | `loop_physics` | 'rig' | evidence | [] | [check.ts:
|
|
10813
|
-
| `requirements.lines.* (bone)` | `requirements.lines.*` | 'rig' | finding when line.status === 'FAIL'; otherwise evidence | [] | [check.ts:
|
|
10814
|
-
| `requirements.lines.* (seam)` | `requirements.lines.*` | 'pair' | finding when line.status === 'FAIL'; otherwise evidence | [r.part, r.neighbour] | [check.ts:
|
|
10815
|
-
| `requirements.lines.* (stretch)` | `requirements.lines.*` | part when the supplied mapping resolves a piece; otherwise rig | finding when line.status === 'FAIL'; otherwise evidence | resolved piece for r.slot; otherwise [] | [check.ts:
|
|
10816
|
-
| `seam_cells.frames` | `frames` | 'pair' | evidence | [p.a, p.b] | [check.ts:
|
|
10817
|
-
| `seam_cells.frames[].cells` | `frames[].cells` | part when the supplied mapping resolves a piece; otherwise rig | evidence | resolved piece for cell.setupTop ?? ''; otherwise [] | [check.ts:
|
|
10818
|
-
| `seam_pairs` | `seam_pairs`; `seam_scope.whole_pairs`; `sets.*.seam_pairs`; `sets.*.seam_scope.whole_pairs` | subjects.length === 0 ? 'rig' : subjects.length === 1 ? 'part' : 'pair' | evidence | subjects | [check.ts:
|
|
10819
|
-
| `seam_scope.changes` | `seam_scope.changes`; `sets.*.seam_scope.changes` | 'rig' | evidence | [] | [check.ts:
|
|
10820
|
-
| `seam_scope.domain.states` | `seam_scope.domain.states`; `sets.*.seam_scope.domain.states` | 'rig' | evidence | [] | [check.ts:
|
|
10821
|
-
| `seam_scope.pairs` | `seam_scope.pairs`; `sets.*.seam_scope.pairs` | subjects.length === 0 ? 'rig' : subjects.length === 1 ? 'part' : 'pair' | evidence | subjects | [check.ts:
|
|
10822
|
-
| `seam_scope.population.pairs` | `seam_scope.population.pairs`; `sets.*.seam_scope.population.pairs` | 'pair' | evidence | row.parts | [check.ts:
|
|
10823
|
-
| `seam_scope.population.single_art` | `seam_scope.population.single_art`; `sets.*.seam_scope.population.single_art` | 'part' | evidence | [row.part] | [check.ts:
|
|
10848
|
+
| `STILL_REGIONS_DARK.*.crossing` | `STILL_REGIONS_DARK.*.crossing` | part when the supplied mapping resolves a piece; otherwise rig | finding | resolved piece for sl.name; otherwise [] | [check.ts:9537](../src/check.ts#L9537) |
|
|
10849
|
+
| `STILL_REGIONS_DARK.*.still_slots` | `STILL_REGIONS_DARK.*.still_slots` | part when the supplied mapping resolves a piece; otherwise rig | evidence; finding when r.max > tolerance; otherwise evidence | resolved piece for slot; otherwise [] | [check.ts:9523](../src/check.ts#L9523), [check.ts:9528](../src/check.ts#L9528) |
|
|
10850
|
+
| `STRESS_OFF_CHAIN.not_read` | `STRESS_OFF_CHAIN.not_read` | 'part' | evidence | [r.part] | [check.ts:4299](../src/check.ts#L4299) |
|
|
10851
|
+
| `STRESS_OFF_CHAIN.per_part` | `STRESS_OFF_CHAIN.per_part` | 'part' | finding when poses.some(p => typeof p.reading === 'number' && p.reading > STRESS_RIGID); otherwise evidence | [r.part] | [check.ts:4287](../src/check.ts#L4287) |
|
|
10852
|
+
| `STRESS_OFF_CHAIN.per_part[].off_chain` | `STRESS_OFF_CHAIN.per_part[].off_chain` | 'part' | evidence | [r.part] | [check.ts:4287](../src/check.ts#L4287) |
|
|
10853
|
+
| `STRESS_OFF_CHAIN.per_part[].poses` | `STRESS_OFF_CHAIN.per_part[].poses` | 'part' | evidence; finding when shown > STRESS_RIGID; otherwise evidence | [r.part] | [check.ts:4255](../src/check.ts#L4255), [check.ts:4273](../src/check.ts#L4273) |
|
|
10854
|
+
| `TEXTURE_STRETCH.per_mesh` | `TEXTURE_STRETCH.per_mesh` | part when the supplied mapping resolves a piece; otherwise rig | evidence; finding when severity > TEXTURE_STRETCH_CEILING; otherwise evidence | resolved piece for m.slot; otherwise [] | [check.ts:10304](../src/check.ts#L10304), [check.ts:10314](../src/check.ts#L10314) |
|
|
10855
|
+
| `TIP_OVER_ROOT.parts` | `TIP_OVER_ROOT.parts` | 'part' | evidence; finding when !ok && !(!rigid && hanging.onLink && Math.max(c.root, c.tip) < TIP_TRAVEL_FLOOR); otherwise evidence | [p.name] | [check.ts:8912](../src/check.ts#L8912), [check.ts:8917](../src/check.ts#L8917), [check.ts:8938](../src/check.ts#L8938), [check.ts:8949](../src/check.ts#L8949) |
|
|
10856
|
+
| `WIND_BAND.pairs` | `WIND_BAND.pairs` | 'pair' | finding when !holdsAll; otherwise evidence | [p.a, p.b] | [check.ts:6833](../src/check.ts#L6833) |
|
|
10857
|
+
| `WIND_BAND.pairs[].steps` | `WIND_BAND.pairs[].steps` | 'pair' | finding when !s.holds; otherwise evidence | [p.a, p.b] | [check.ts:6844](../src/check.ts#L6844) |
|
|
10858
|
+
| `figure_openings.openings` | `figure_openings.openings` | 'pair' | finding | [ps.under, ps.above] | [check.ts:6150](../src/check.ts#L6150) |
|
|
10859
|
+
| `loop_physics` | `loop_physics` | 'rig' | evidence | [] | [check.ts:7947](../src/check.ts#L7947) |
|
|
10860
|
+
| `requirements.lines.* (bone)` | `requirements.lines.*` | 'rig' | finding when line.status === 'FAIL'; otherwise evidence | [] | [check.ts:8280](../src/check.ts#L8280) |
|
|
10861
|
+
| `requirements.lines.* (seam)` | `requirements.lines.*` | 'pair' | finding when line.status === 'FAIL'; otherwise evidence | [r.part, r.neighbour] | [check.ts:8280](../src/check.ts#L8280) |
|
|
10862
|
+
| `requirements.lines.* (stretch)` | `requirements.lines.*` | part when the supplied mapping resolves a piece; otherwise rig | finding when line.status === 'FAIL'; otherwise evidence | resolved piece for r.slot; otherwise [] | [check.ts:8280](../src/check.ts#L8280) |
|
|
10863
|
+
| `seam_cells.frames` | `frames` | 'pair' | evidence | [p.a, p.b] | [check.ts:5030](../src/check.ts#L5030) |
|
|
10864
|
+
| `seam_cells.frames[].cells` | `frames[].cells` | part when the supplied mapping resolves a piece; otherwise rig | evidence | resolved piece for cell.setupTop ?? ''; otherwise [] | [check.ts:4990](../src/check.ts#L4990) |
|
|
10865
|
+
| `seam_pairs` | `seam_pairs`; `seam_scope.whole_pairs`; `sets.*.seam_pairs`; `sets.*.seam_scope.whole_pairs` | subjects.length === 0 ? 'rig' : subjects.length === 1 ? 'part' : 'pair' | evidence | subjects | [check.ts:2708](../src/check.ts#L2708) |
|
|
10866
|
+
| `seam_scope.changes` | `seam_scope.changes`; `sets.*.seam_scope.changes` | 'rig' | evidence | [] | [check.ts:2186](../src/check.ts#L2186) |
|
|
10867
|
+
| `seam_scope.domain.states` | `seam_scope.domain.states`; `sets.*.seam_scope.domain.states` | 'rig' | evidence | [] | [check.ts:2271](../src/check.ts#L2271) |
|
|
10868
|
+
| `seam_scope.pairs` | `seam_scope.pairs`; `sets.*.seam_scope.pairs` | subjects.length === 0 ? 'rig' : subjects.length === 1 ? 'part' : 'pair' | evidence | subjects | [check.ts:7797](../src/check.ts#L7797) |
|
|
10869
|
+
| `seam_scope.population.pairs` | `seam_scope.population.pairs`; `sets.*.seam_scope.population.pairs` | 'pair' | evidence | row.parts | [check.ts:2642](../src/check.ts#L2642) |
|
|
10870
|
+
| `seam_scope.population.single_art` | `seam_scope.population.single_art`; `sets.*.seam_scope.population.single_art` | 'part' | evidence | [row.part] | [check.ts:2643](../src/check.ts#L2643) |
|
|
10824
10871
|
|
|
10825
10872
|
| Serialized type path | Reason for schema exclusion |
|
|
10826
10873
|
| --- | --- |
|
package/docs/STABILITY.md
CHANGED
|
@@ -602,7 +602,7 @@ and do not certify visibility. See the
|
|
|
602
602
|
| `check` | `--rig`, `--out`; optional `--parts`, `--source`, `--page-edges`, `--pack-shape`, `--page-size`, `--requirements`, `--seam-pairs`, `--keep-stills`, `--no-extremes` (issue #829), `--set` or `--all-sets` (issue #454), `--environment` (issue #538, additive), `--wind-band` (issue #590, additive), paired `--loop-seam-bar` and `--loop-seam-cap` (issue #1590), `--json` (issue #904), `--help` (`-h`) |
|
|
603
603
|
| `loop` | `--frames`, `--out`; optional `--palette`, `--help` (`-h`) |
|
|
604
604
|
| `build` | `--config`, `--source`, `--full`, `--out`; optional `--head` (as for `assemble`), `--seam`, `--project`, `--page-edges`, `--pack-shape`, `--page-size`, `--loop`, `--lead-in`, `--requirements`, `--idle-keys`, `--seam-pairs`, `--keep-stills`, `--no-extremes` (issue #829), `--alt` (as for `assemble`, issue #454), `--set` or `--all-sets` (as for `check`, issue #454), `--environment` (as for `check`, issue #538, additive), `--wind-band` (as for `check`, issue #590, additive), `--help` (`-h`) |
|
|
605
|
-
| `compose` | `--scene`, `--out`; optional `--requirements`, `--accept`, `--page-size`, paired `--loop-seam-bar` and `--loop-seam-cap` (issue #1590), `--help` (`-h`) |
|
|
605
|
+
| `compose` | `--scene`, `--out`; optional `--requirements`, `--accept`, `--page-size`, paired `--loop-seam-bar` and `--loop-seam-cap` (issue #1590), `--output-profile` (`preview`) and `--no-extremes` (issue #1610), `--help` (`-h`) |
|
|
606
606
|
| `mesh-draft` | `--config`, `--parts`, `--out`; optional `--requirements`, `--idle-keys` (ctl, direct), `--page-edges` (pot, free), `--pack-shape` (rect, polygon), `--page-size`, `--more-triangles`, `--help` (`-h`) |
|
|
607
607
|
| `mesh-stats` | `--config`, `--parts`; optional `--help` (`-h`) (issue #566, additive: prints, writes nothing) |
|
|
608
608
|
| `remesh` | `--rig`, `--config`, `--parts`, `--part`, `--out`, and one of `--mesh` or `--delta` (issue #526); optional `--requirements`, `--idle-keys` (ctl, direct), `--page-edges` (pot, free), `--pack-shape` (rect, polygon), `--page-size`, `--record-input-check` and `--input-check` (issue #617, additive: without them nothing `remesh` prints or writes changes), `--help` (`-h`) |
|
|
@@ -1194,7 +1194,8 @@ execution in historical evidence is inferred from a current export.
|
|
|
1194
1194
|
| scene loop refusal detail | `compose` | Issue #1358 enriches `SCENE_ANIMATION_LOOP_CLOSES` with the first differing bone or slot, channel, start/end values and numeric tolerance 0 (exact equality), and issue #1590 states in the detail that it checks posed endpoint values with physics omitted and does not measure physics-on frames. The existing exact JSON endpoint comparison is unchanged: bones, slots, draw order, drawn geometry, clipping polygons and clipped geometry remain covered. Selection follows that family order, then producer row and field order; geometry-only differences name the slot and geometry channel. Physics is omitted from this posed-value comparison, and the refusal code, acceptance, emitted rig/motion and built scene bytes are unchanged. |
|
|
1195
1195
|
| scene canvas framing | `compose` | Issue #1491 adds optional `characters[].canvas_clip` to `spine-parts-scene/1`. Literal `true` requires finite placed bounds, overflow past a canvas edge and an intersection with positive width and height. The respective refusals are `SCENE_CHARACTER_CLIP_BOUNDS`, `SCENE_CHARACTER_CLIP_UNUSED` and `SCENE_CHARACTER_CLIP_EMPTY`. Other explicit values are `SCENE_FIELD_TYPE`. Omitting the key retains the exact containment rule, output bytes and console text. The opted-in character row in `scene.json` adds `canvas_clip: true` and `clipped_bounds` after the original `bounds`. Both boxes are canvas pixels, y down, with exclusive right and bottom edges. The console appends the clipped box only for those rows. The rig-c gate and packed build retain the full art and geometry. For a scene with any opt-in, compose check renders use the stage viewport unless the render specifies its own. Preview size caps and sampling stay in effect. Native-size renders and consumer playback use the authored stage rectangle as described in [Canvas framing for intentional overflow](AUTHORING.md#canvas-framing-for-intentional-overflow-issue-1491). |
|
|
1196
1196
|
| scene placement pivot | `compose` | Issue #1498 adds optional literal `true` at `characters[].placement_pivot` in `spine-parts-scene/1`. It emits the identity `<id>:placement` under `root` and requires a scene-authored `translate`, `translatex` or `translatey` key in final scene pixels. The existing placement math stays on the original first-level bones, root regions and root weights. Source root bindings use the unkeyed identity `<id>:root` child when needed. `SCENE_FIELD_TYPE` refuses other explicit values, `SCENE_PIVOT_NAME_FREE` a source bone collision, `SCENE_PIVOT_DECLARED` an unresolved pivot targeted directly or through a bone group without an opt-in, `SCENE_PIVOT_UNUSED` an unused declaration and `SCENE_PIVOT_TRACK` a forbidden property or carrier key. `SCENE_PLATE_NAME_FREE` still governs named plate collisions. Core's unknown-bone refusal, rig gate, scene clip timing and endpoint closure still apply. `scene.json` adds `placement_pivot` with the generated name after the bounds fields and counts the generated bones for that character. `compose-run.json` binds the declaration through `scene.sha256` with its existing shape and key order. Omitting the declaration preserves default output bytes at the same paths, subject to the existing Core receipt clocks. |
|
|
1197
|
-
| `compose-run.json` | `compose` | spec `rig-compose-run/1` (issue #1348), separate from `rig-run/1`; a stable contract as of 2.44.0. Written at the `--out` root only after the gate and check are green and no accepted failing character remains
|
|
1197
|
+
| `compose-run.json` | `compose` | spec `rig-compose-run/1` (issue #1348), separate from `rig-run/1`; a stable contract as of 2.44.0. Written at the `--out` root only after the gate and check are green and no accepted failing character remains. Fixed keys in order: `spec`, `scene` (`path`, `sha256`), `characters` (each `id`, `build`, `files`, each file `path`, `sha256`, then optional `placement`), `plate` (`path`, `sha256`, or null), `plates` (each `name`, `path`, `sha256`), then optional `output_profile` (`"preview"` or `"no-extremes"`, issue #1610). Scene and plate paths are the supplied and declared paths; character file paths are build-relative. Characters sort by `id`, files by `path`, named plates by `name`, in code-unit order. Each character's files are exactly `check/check.json`, `parts.json`, `rig/rig.json`, `rig/motion.json` and each distinct image the default skin names under `rig/images/`, including a generator's depth image. Every `sha256` is of the raw file bytes compose consumed before the gate. Only a character with `canvas_clip: true` has `placement`, with `canvas_clip: true`, `bounds` and `clipped_bounds` in that order from the scene report. Identical inputs at identical supplied paths with the same output profile give identical record bytes. The receipt inventories the listed inputs and selected profile, without clocks. Compose owns the name: a file of that name at the `--out` root is deleted at the start of every compose, before stage validation, so a refused rerun leaves none. |
|
|
1198
|
+
| compose output profiles | `compose` | Issue #1610 adds `--no-extremes` to omit only the extremes diagnostic renders, and `--output-profile preview` to also omit `check/idle_frames/`, `check/contact.png` and `check/motion_heat.png`. Preview takes precedence when both flags are given. Preview uses the stock idle render and existing readers. Before preview success, Parts removes the idle render directory, including Core's temporary contact sheet, skips copying the sheet to the check root, and skips generating heat. Each omission has a diagnostic `SKIP` line naming its selected flag. The gate, camera binding and check requirements still apply. Success prints `compose: PREVIEW — checks met; …` or `compose: NO EXTREMES — checks met; …`, respectively, and writes `output_profile` as `"preview"` or `"no-extremes"`. Default compose keeps its existing file bytes (with the nested Core receipt clock comparison described above), output paths and `compose: PASS — …` line. `COMPOSE_PREVIEW_REQUIRED_CHECK` refuses a valid loop seam pair in preview with `found=preview, required=default or no-extremes`, because the `loop_seam` record in `check.json` binds the paths and hashes of first and wrap PNGs that must remain under `check/idle_frames/`. Compose clears its owned outputs before this refusal. See [Compose output profiles](AUTHORING.md#compose-output-profiles-issue-1610). |
|
|
1198
1199
|
| the scene report | `compose` | spec `spine-parts-scene-report/1`; the plate block carries `sha256` of the plate PNG's bytes after `size` (issue #1183, additive under *What "stable" means here*: a new report key in a minor version, so the spec stays `/1`); `pack_mode` records `page_size` only when `--page-size <px>` is given (issue #1352, additive; without `--page-size`, rigc's default 2048 px page and padding 2 on each side bound any plate or region side to at most 2044 px before `CE_ATLAS_REGION_EXCEEDS_PAGE`) |
|
|
1199
1200
|
| keyed scene camera | `compose` | optional `camera` in `spine-parts-scene/1` (issue #1596). A camera scene writes `spine-parts-scene-report/2` at the existing `scene.json` path with its keyed camera, sampled coverage and framing verdict, and packed model SHA-256. Report /1 and the existing output inventory and bytes are preserved for scenes without a camera, subject to the existing Core receipt clocks. The camera path uses Core animation easing and the posed backdrop at each sampled frame. Rig, motion and stock check outputs retain their existing semantics. The compose input receipt stays `rig-compose-run/1`. See [Keyed scene camera](AUTHORING.md#keyed-scene-camera-issue-1596) |
|
|
1200
1201
|
| `idle.png`, `idle-indexed.png`, `idle.gif` | `loop`, `build --loop` | APNG and GIF encodings of the rendered idle |
|
|
@@ -1333,7 +1334,9 @@ number from 0 to 255, and the pixel limit and cap are nonnegative safe integers.
|
|
|
1333
1334
|
The pair requires a positive idle period and is incompatible with `--environment`.
|
|
1334
1335
|
Core selects the first take meeting the RGBA bar from warm-up 0 through the cap,
|
|
1335
1336
|
at the viewport used for the shipped idle, including the canvas viewport when
|
|
1336
|
-
compose applies it. Without physics Core tries 0 only.
|
|
1337
|
+
compose applies it. Without physics Core tries 0 only. Compose supports the
|
|
1338
|
+
pair with default diagnostics or `--no-extremes`. With `--output-profile preview`,
|
|
1339
|
+
`COMPOSE_PREVIEW_REQUIRED_CHECK` refuses the pair before the gate.
|
|
1337
1340
|
|
|
1338
1341
|
The optional `loop_seam` follows `loop_max_diff` and any `loop_physics` in the
|
|
1339
1342
|
report. It contains Core's exact `rigc-loop-seam/1` object with `status: "met"`.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "rig-parts",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.64.0",
|
|
4
4
|
"description": "AI-authored 2D character parts from one anime painting and its See-through layer decomposition: measured parts, weighted-mesh rig specs, verified through rig-c before anything is written. A CLI for agents that cannot see the image.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|
package/src/build.ts
CHANGED
|
@@ -2201,6 +2201,8 @@ export interface CheckStageInput {
|
|
|
2201
2201
|
keepStills?: boolean;
|
|
2202
2202
|
/** Skip the extra extremes renders and remove stale extremes outputs (issue #829). */
|
|
2203
2203
|
noExtremes?: boolean;
|
|
2204
|
+
/** Use the stock idle render as scratch for compose preview. */
|
|
2205
|
+
previewIdle?: boolean;
|
|
2204
2206
|
/** Declared RGBA loop seam bar and warm-up cap for the shipped idle render (issue #1590). */
|
|
2205
2207
|
loopSeam?: LoopSeamRequest;
|
|
2206
2208
|
/** `check --set <name>` (issue #454): measure one declared alternate set's setup-pose seam and recomposite figures. */
|
|
@@ -2447,10 +2449,10 @@ export function requirementText(name: string, line: RequirementLine): string {
|
|
|
2447
2449
|
* check wrote them, then the directories it wrote whole (`build`, and `idle_frames`, the requirements, seam and
|
|
2448
2450
|
* setup-still directories when they were written). The `check-run.json` record lists the files under these.
|
|
2449
2451
|
*/
|
|
2450
|
-
export function checkWrote(r: CheckReport, out: string): { written: string[]; dirs: string[] } {
|
|
2452
|
+
export function checkWrote(r: CheckReport, out: string, previewIdle = false): { written: string[]; dirs: string[] } {
|
|
2451
2453
|
return {
|
|
2452
2454
|
written: r.written,
|
|
2453
|
-
dirs: ['build', ...(r.idle === null ? [] : ['idle_frames']), ...(r.requirements === null ? [] : [REQUIREMENTS_DIR]),
|
|
2455
|
+
dirs: ['build', ...(r.idle === null || previewIdle ? [] : ['idle_frames']), ...(r.requirements === null ? [] : [REQUIREMENTS_DIR]),
|
|
2454
2456
|
...(r.figures.seam_pairs === undefined ? [] : [SEAM_DIR]), ...(existsSync(join(out, STILL_DIR)) ? [STILL_DIR] : [])],
|
|
2455
2457
|
};
|
|
2456
2458
|
}
|
|
@@ -2471,7 +2473,7 @@ export function checkStage(input: CheckStageInput, rigc: RigcRunner, bin: string
|
|
|
2471
2473
|
const r = runCheck(
|
|
2472
2474
|
input.rig, input.out, rigc, input.parts, mode, input.source, input.requirements, input.seamPairs === true,
|
|
2473
2475
|
input.keepStills === true, input.set, input.allSets === true, input.environment, input.requirementsAs, input.config,
|
|
2474
|
-
input.windBand, input.noExtremes === true, input.supportSource, input.supportFigure, input.assemblyRules, input.loopSeam,
|
|
2476
|
+
input.windBand, input.noExtremes === true, input.supportSource, input.supportFigure, input.assemblyRules, input.loopSeam, input.previewIdle,
|
|
2475
2477
|
);
|
|
2476
2478
|
if (r.figures.environment !== undefined) log(` ${environmentLine(r.figures.environment)}`);
|
|
2477
2479
|
log(` gate rig-play (rigc ${packedBuildLabel(mode)}), verbatim:`);
|
|
@@ -2559,7 +2561,7 @@ export function checkStage(input: CheckStageInput, rigc: RigcRunner, bin: string
|
|
|
2559
2561
|
log(` ${summaryText(r.requirements.summary)}`);
|
|
2560
2562
|
}
|
|
2561
2563
|
log(` gate: rig-play ${fig.gate_spine_html_green ? 'green' : 'RED'} (${fig.rigc_entry.entry}${fig.rigc_entry.spine_core === null ? ', rigc\'s own validator' : `, the spine-core ${fig.rigc_entry.spine_core} round trip`})`);
|
|
2562
|
-
const wrote = checkWrote(r, input.out);
|
|
2564
|
+
const wrote = checkWrote(r, input.out, input.previewIdle);
|
|
2563
2565
|
log(` wrote ${[...wrote.written.map((w) => join(input.out, w)), ...wrote.dirs.map((d) => `${join(input.out, d)}/`)].join(', ')}`);
|
|
2564
2566
|
for (const p of r.problems) log(failLine(p));
|
|
2565
2567
|
log(checkSummaryLine(r));
|
package/src/check.ts
CHANGED
|
@@ -98,7 +98,7 @@ import { createHash } from 'node:crypto';
|
|
|
98
98
|
import { createRequire } from 'node:module';
|
|
99
99
|
import type { Candidate, Piece, Viewport as RootCoverageViewport } from '@rig-c/core/render-shared';
|
|
100
100
|
import { fillHoles } from './raster/morph.ts';
|
|
101
|
-
import { closeSync, copyFileSync, cpSync, existsSync, mkdirSync, openSync, readdirSync, readFileSync, readSync, renameSync, rmSync, statSync, writeFileSync, writeSync } from 'node:fs';
|
|
101
|
+
import { closeSync, copyFileSync, cpSync, existsSync, mkdirSync, openSync, readdirSync, readFileSync, readSync, realpathSync, renameSync, rmSync, statSync, writeFileSync, writeSync } from 'node:fs';
|
|
102
102
|
import { argvPathFromOut, diagnosticSegment, diagnosticSiblings, unsafeSegmentReason } from './outputpaths.ts';
|
|
103
103
|
import { basename, delimiter, dirname, isAbsolute, join, relative, resolve, sep } from 'node:path';
|
|
104
104
|
import { measureRecomposite, type RecompositeFigures, recompositeRecord, scenePhrase, sourceInRig, figureSilhouette } from './assemble.ts';
|
|
@@ -153,7 +153,9 @@ import {
|
|
|
153
153
|
import { type AlternatePartsRecord, FRONT_SUFFIX, type LimbRecord, partImageReference, type PartRecord, type PartsFile, readParts } from './parts.ts';
|
|
154
154
|
import { ARM_SPLIT_MIGRATION, poseRigBonesForDrawn, type RigBone, SETS_FILE, writtenShares } from './rig.ts';
|
|
155
155
|
import { TURN_BONE, turnConstraintName, turnTwin } from './turn.ts';
|
|
156
|
-
import { ROOT_BONE, loadConfigWithBytes, type Point } from './config.ts';
|
|
156
|
+
import { type CharacterConfig, contourRegionsOf, ROOT_BONE, loadConfigWithBytes, type Point } from './config.ts';
|
|
157
|
+
import { GRID } from './contour.ts';
|
|
158
|
+
import { regionBandSite, regionWeight, type RegionBandSite } from './localweights.ts';
|
|
157
159
|
import { influences, meshLimits, type Segment, type Influence, type InfluenceLimits } from './weights.ts';
|
|
158
160
|
import {
|
|
159
161
|
requirementAnimations,
|
|
@@ -231,7 +233,7 @@ const STILL_FPS = 10;
|
|
|
231
233
|
|
|
232
234
|
/** The caller's RGBA seam bar and maximum number of warm-up loops. */
|
|
233
235
|
export type LoopSeamRequest = { channelDelta: number; pixelsAbove: number; cap: number };
|
|
234
|
-
|
|
236
|
+
export const COMPOSE_PREVIEW_LOOP_SEAM_DETAIL = 'found=preview, required=default or no-extremes. The check.json loop_seam record binds the first and wrap PNG paths and hashes under check/idle_frames/, which preview removes.';
|
|
235
237
|
const LOOP_SEAM_SPEC = 'rigc-loop-seam/1';
|
|
236
238
|
export const LOOP_SEAM_BAR_UNMET = 'LOOP_SEAM_BAR_UNMET';
|
|
237
239
|
const LOOP_SEAM_FILE = 'loop-seam.json';
|
|
@@ -6968,6 +6970,7 @@ function renderExtremes(build: string, out: string, animations: readonly string[
|
|
|
6968
6970
|
* or `motion_heat.png`). A declared `loopSeam` requires a positive idle and
|
|
6969
6971
|
* binds Core's met wrap-seam report to the shipped render. The keyed reading
|
|
6970
6972
|
* still runs. `source` (`--source`) adds {@link SOURCE_LINE}.
|
|
6973
|
+
* Compose preview reads the stock idle render as scratch and omits the idle diagnostics.
|
|
6971
6974
|
*
|
|
6972
6975
|
* `requirements` (`--requirements`, issue #93) is read with the rig directory
|
|
6973
6976
|
* and resolved against it before anything is built ({@link readRequirements},
|
|
@@ -6977,9 +6980,14 @@ function renderExtremes(build: string, out: string, animations: readonly string[
|
|
|
6977
6980
|
* MEASURABLE is a problem. Without it nothing here reads, writes or prints
|
|
6978
6981
|
* anything it did not before.
|
|
6979
6982
|
*/
|
|
6980
|
-
export function runCheck(rigDir: string, outDir: string, rigc: RigcRunner, partsHome?: string, mode: PackMode = DEFAULT_PACK_MODE, source?: string, requirements?: string, seamPairsAsked = false, keepStills = false, set?: string, allSets = false, environment?: string, _requirementsAs: string | undefined = requirements, config?: InputFileRecord, windBand?: string, noExtremes = false, supportSource?: string, supportFigure?: Mask, assemblyRules?: AssemblyRules, loopSeam?: LoopSeamRequest): CheckReport {
|
|
6983
|
+
export function runCheck(rigDir: string, outDir: string, rigc: RigcRunner, partsHome?: string, mode: PackMode = DEFAULT_PACK_MODE, source?: string, requirements?: string, seamPairsAsked = false, keepStills = false, set?: string, allSets = false, environment?: string, _requirementsAs: string | undefined = requirements, config?: InputFileRecord, windBand?: string, noExtremes = false, supportSource?: string, supportFigure?: Mask, assemblyRules?: AssemblyRules, loopSeam?: LoopSeamRequest, previewIdle = false): CheckReport {
|
|
6981
6984
|
const out = resolve(outDir);
|
|
6982
|
-
if (loopSeam !== undefined) rmSync(join(out, 'check.json'), { force: true });
|
|
6985
|
+
if (loopSeam !== undefined || previewIdle) rmSync(join(out, 'check.json'), { force: true });
|
|
6986
|
+
if (previewIdle && loopSeam !== undefined) throw new PartsError([{
|
|
6987
|
+
code: 'COMPOSE_PREVIEW_REQUIRED_CHECK',
|
|
6988
|
+
object: '--loop-seam-bar',
|
|
6989
|
+
detail: COMPOSE_PREVIEW_LOOP_SEAM_DETAIL,
|
|
6990
|
+
}]);
|
|
6983
6991
|
const pageSize = parsePageSize(mode.pageSize);
|
|
6984
6992
|
let inp: CheckInputs;
|
|
6985
6993
|
let reqFile: RequirementsFile | null = null;
|
|
@@ -7067,7 +7075,8 @@ export function runCheck(rigDir: string, outDir: string, rigc: RigcRunner, parts
|
|
|
7067
7075
|
const animationNames = isRecord(inp.motion.animations) ? Object.keys(inp.motion.animations) : [];
|
|
7068
7076
|
const selectedAlts = inp.parts === null || (set === undefined && !allSets) ? []
|
|
7069
7077
|
: allSets ? inp.parts.alternates ?? [] : (inp.parts.alternates ?? []).filter(alt => alt.name === set);
|
|
7070
|
-
|
|
7078
|
+
const omitExtremes = noExtremes || previewIdle;
|
|
7079
|
+
preflightCheckPaths(animationNames, selectedAlts.map(alt => alt.name), reqFile, omitExtremes);
|
|
7071
7080
|
// A measured material failure is a check bar; unavailable data is a refusal.
|
|
7072
7081
|
const rigcEntry = readRigcEntry(requireRigcVersion(rigc));
|
|
7073
7082
|
/**
|
|
@@ -7100,6 +7109,9 @@ export function runCheck(rigDir: string, outDir: string, rigc: RigcRunner, parts
|
|
|
7100
7109
|
const seamMotionDir = join(out, MOTION_SEAM_SCRATCH);
|
|
7101
7110
|
const windBandDir = join(out, WIND_BAND_SCRATCH);
|
|
7102
7111
|
for (const d of [join(out, 'extremes'), join(out, '_extremes'), buildDir, buildReportPath, idleDir, stillDir, isoDir, loopDir, seamDir, keptDir, join(out, 'setup_still_auto'), foldDir, seamMotionDir, windBandDir]) rmSync(d, { recursive: true, force: true });
|
|
7112
|
+
if (previewIdle) {
|
|
7113
|
+
for (const name of ['contact.png', 'motion_heat.png']) rmSync(join(out, name), { force: true });
|
|
7114
|
+
}
|
|
7103
7115
|
const written: string[] = [];
|
|
7104
7116
|
const write = (name: string, data: string): void => {
|
|
7105
7117
|
writeFileSync(join(out, name), data);
|
|
@@ -7219,7 +7231,7 @@ export function runCheck(rigDir: string, outDir: string, rigc: RigcRunner, parts
|
|
|
7219
7231
|
}
|
|
7220
7232
|
loopSeamEvidence = checked?.report ?? null;
|
|
7221
7233
|
const contact = join(idle.dir, 'contact.png');
|
|
7222
|
-
if (existsSync(contact)) {
|
|
7234
|
+
if (!previewIdle && existsSync(contact)) {
|
|
7223
7235
|
copyFileSync(contact, join(out, 'contact.png'));
|
|
7224
7236
|
written.push('contact.png');
|
|
7225
7237
|
}
|
|
@@ -7246,9 +7258,11 @@ export function runCheck(rigDir: string, outDir: string, rigc: RigcRunner, parts
|
|
|
7246
7258
|
loop = maxRgbDiff(kept.frames[0].image, keptLast.image);
|
|
7247
7259
|
loopSet = kept;
|
|
7248
7260
|
}
|
|
7249
|
-
|
|
7250
|
-
|
|
7251
|
-
|
|
7261
|
+
if (!previewIdle) {
|
|
7262
|
+
const idleImages = idle.frames.map((f) => f.image);
|
|
7263
|
+
writePng(join(out, 'motion_heat.png'), motionHeat(idleImages));
|
|
7264
|
+
written.push('motion_heat.png');
|
|
7265
|
+
}
|
|
7252
7266
|
}
|
|
7253
7267
|
|
|
7254
7268
|
// 3a. every animation, the idle included, read for folds by rigc (issues #320, #333, #363) — only when there is one; at
|
|
@@ -7325,7 +7339,7 @@ export function runCheck(rigDir: string, outDir: string, rigc: RigcRunner, parts
|
|
|
7325
7339
|
level = levelLine(feet, inp.rig, levelReadings, fps, stripped.physics.length, levelProblems);
|
|
7326
7340
|
}
|
|
7327
7341
|
}
|
|
7328
|
-
if (!
|
|
7342
|
+
if (!omitExtremes) extremesFrames = readJson(join(stripped === null ? foldDir : join(foldDir, 'on'), 'frames.json'), []);
|
|
7329
7343
|
} finally {
|
|
7330
7344
|
rmSync(foldDir, { recursive: true, force: true });
|
|
7331
7345
|
}
|
|
@@ -8017,13 +8031,14 @@ export function runCheck(rigDir: string, outDir: string, rigc: RigcRunner, parts
|
|
|
8017
8031
|
...readings,
|
|
8018
8032
|
PASS: problems.length === 0,
|
|
8019
8033
|
};
|
|
8034
|
+
if (previewIdle) rmSync(idleDir, { recursive: true, force: true });
|
|
8020
8035
|
const publishCheck = (): void => {
|
|
8021
8036
|
publishMotionSeamCells(out, motionSeam.required, motionCellEvidence, () => write('check.json', serializeCheckRows(figures)));
|
|
8022
8037
|
if (motionSeam.required?.cells !== undefined) written.push(MOTION_CELLS_FILE);
|
|
8023
8038
|
};
|
|
8024
8039
|
if (motionSeam.worlds === undefined) publishCheck();
|
|
8025
8040
|
else publishMotionSeamWorlds(out, seamMotionDir, motionSeam.worlds, publishCheck);
|
|
8026
|
-
const extremes =
|
|
8041
|
+
const extremes = omitExtremes ? [] : renderExtremes(buildDir, out, animationNames, idle === null ? extremesFrames : readJson(join(idleDir, 'frames.json'), []), extremesFrames, measured);
|
|
8027
8042
|
if (existsSync(join(out, 'extremes'))) written.push('extremes/');
|
|
8028
8043
|
const bars: CheckReport['bars'] = { measured: ['gate'], skipped: [] };
|
|
8029
8044
|
const tally = (bar: string, reason: string | null): void => {
|
|
@@ -8079,6 +8094,7 @@ export function runCheck(rigDir: string, outDir: string, rigc: RigcRunner, parts
|
|
|
8079
8094
|
...(windBandRead === null ? {} : { windBand: windBandRead }),
|
|
8080
8095
|
};
|
|
8081
8096
|
} finally {
|
|
8097
|
+
if (previewIdle) rmSync(idleDir, { recursive: true, force: true });
|
|
8082
8098
|
rmSync(seamMotionDir, { recursive: true, force: true });
|
|
8083
8099
|
}
|
|
8084
8100
|
}
|
|
@@ -9970,10 +9986,127 @@ function stretchAtText(s: { triangle: number; vertices: readonly number[]; edge:
|
|
|
9970
9986
|
export interface WeightStepContext {
|
|
9971
9987
|
config?: InputFileRecord;
|
|
9972
9988
|
stage?: StageBox;
|
|
9989
|
+
rigDir?: string;
|
|
9973
9990
|
}
|
|
9974
9991
|
|
|
9975
9992
|
type StepBinding = { bone: string; x: number; y: number; weight: number };
|
|
9976
9993
|
|
|
9994
|
+
const RIG_RUN_STAMP_FILE = 'run.json';
|
|
9995
|
+
const RIG_RUN_STAMP_SPEC = 'rig-run/1';
|
|
9996
|
+
const CONTOUR_GRID_TOLERANCE = 1e-2;
|
|
9997
|
+
|
|
9998
|
+
/** Load a hash-verified config from an explicit record (`build`) or the rig directory's `rig-run/1` stamp (`check`). */
|
|
9999
|
+
function loadVerifiedContourConfig(context?: WeightStepContext): CharacterConfig | null {
|
|
10000
|
+
if (context === undefined) return null;
|
|
10001
|
+
try {
|
|
10002
|
+
if (context.config !== undefined) {
|
|
10003
|
+
const loaded = loadConfigWithBytes(context.config.path);
|
|
10004
|
+
return inputFileRecord(loaded.bytes, context.config.path).sha256 === context.config.sha256 ? loaded.config : null;
|
|
10005
|
+
}
|
|
10006
|
+
if (context.rigDir !== undefined) {
|
|
10007
|
+
const stampPath = join(context.rigDir, RIG_RUN_STAMP_FILE);
|
|
10008
|
+
if (!existsSync(stampPath)) return null;
|
|
10009
|
+
const stamp: unknown = JSON.parse(readFileSync(stampPath, 'utf8'));
|
|
10010
|
+
if (!isRecord(stamp) || stamp.spec !== RIG_RUN_STAMP_SPEC || stamp.command !== 'rig' ||
|
|
10011
|
+
!isRecord(stamp.config) || typeof stamp.config.path !== 'string' || typeof stamp.config.sha256 !== 'string' ||
|
|
10012
|
+
!Array.isArray(stamp.outputs)) return null;
|
|
10013
|
+
const rigEntry = stamp.outputs.find((e): e is Record<string, unknown> => isRecord(e) && e.path === 'rig.json');
|
|
10014
|
+
const rigPath = join(context.rigDir, 'rig.json');
|
|
10015
|
+
if (rigEntry === undefined || typeof rigEntry.sha256 !== 'string' || !existsSync(rigPath)) return null;
|
|
10016
|
+
if (createHash('sha256').update(readFileSync(rigPath)).digest('hex') !== rigEntry.sha256) return null;
|
|
10017
|
+
const cfgPath = resolve(realpathSync(context.rigDir), stamp.config.path);
|
|
10018
|
+
const loaded = loadConfigWithBytes(cfgPath);
|
|
10019
|
+
return inputFileRecord(loaded.bytes, cfgPath).sha256 === stamp.config.sha256 ? loaded.config : null;
|
|
10020
|
+
}
|
|
10021
|
+
} catch {
|
|
10022
|
+
return null;
|
|
10023
|
+
}
|
|
10024
|
+
return null;
|
|
10025
|
+
}
|
|
10026
|
+
|
|
10027
|
+
function bandSiteLabel(site: RegionBandSite): string {
|
|
10028
|
+
if (site === 'band') return 'inside the band';
|
|
10029
|
+
if (site === 'cutoff') return 'at its cutoff';
|
|
10030
|
+
return site === 'region' ? 'inside the region' : 'outside the band';
|
|
10031
|
+
}
|
|
10032
|
+
|
|
10033
|
+
function bandTargetShare(part: string, targetBone: string, bindings: readonly StepBinding[]): number {
|
|
10034
|
+
const twin = turnTwin(part, targetBone);
|
|
10035
|
+
const stopped = `${targetBone}_d`;
|
|
10036
|
+
let share = 0;
|
|
10037
|
+
for (const b of bindings) {
|
|
10038
|
+
if (b.bone === targetBone || b.bone === twin || b.bone === stopped) share += b.weight;
|
|
10039
|
+
}
|
|
10040
|
+
return round6(share);
|
|
10041
|
+
}
|
|
10042
|
+
|
|
10043
|
+
/**
|
|
10044
|
+
* Issue #1598: when a vertex of a failing `TEXTURE_STRETCH` edge lies inside a declared contour band (`0 < d < band`)
|
|
10045
|
+
* or at its cutoff (`d === band`), name the governing contour band — its region, its target bone, its declared width
|
|
10046
|
+
* (`band`), and each vertex's band position and written share — from the verified config declaration and `rig.json`'s
|
|
10047
|
+
* weights alone. Empty for every other edge so unrelated failures keep their text byte for byte.
|
|
10048
|
+
*/
|
|
10049
|
+
export function contourBandText(
|
|
10050
|
+
rig: Record<string, unknown>,
|
|
10051
|
+
slot: string,
|
|
10052
|
+
attachment: string,
|
|
10053
|
+
edge: readonly number[],
|
|
10054
|
+
context?: WeightStepContext,
|
|
10055
|
+
slotParts?: ReadonlyMap<string, string>,
|
|
10056
|
+
): string {
|
|
10057
|
+
if (context?.stage === undefined || edge.length === 0) return '';
|
|
10058
|
+
const cfg = loadVerifiedContourConfig(context);
|
|
10059
|
+
if (cfg === null) return '';
|
|
10060
|
+
const part = slotParts?.get(slot) ?? slot;
|
|
10061
|
+
const meshPart = part in cfg.meshes ? part : slot in cfg.meshes ? slot : null;
|
|
10062
|
+
if (meshPart === null) return '';
|
|
10063
|
+
const mesh = cfg.meshes[meshPart];
|
|
10064
|
+
if (!('contour' in mesh)) return '';
|
|
10065
|
+
const regions = contourRegionsOf(mesh.contour);
|
|
10066
|
+
if (!regions.some((rg) => rg.band > 0)) return '';
|
|
10067
|
+
const skins = isRecord(rig.skins) ? rig.skins : {};
|
|
10068
|
+
const skin = isRecord(skins.default) ? skins.default : {};
|
|
10069
|
+
const onSlot = isRecord(skin[slot]) ? skin[slot] : {};
|
|
10070
|
+
const att = onSlot[attachment];
|
|
10071
|
+
if (!isRecord(att) || !Array.isArray(att.weights)) return '';
|
|
10072
|
+
const transforms = setupWorld(rig);
|
|
10073
|
+
const vertices: Array<{ index: number; point: Point; bindings: StepBinding[] }> = [];
|
|
10074
|
+
for (const v of edge) {
|
|
10075
|
+
const row = att.weights[v];
|
|
10076
|
+
if (!Array.isArray(row) || row.length === 0 || row.some((b) => !isRecord(b) || typeof b.bone !== 'string' ||
|
|
10077
|
+
typeof b.x !== 'number' || typeof b.y !== 'number' || typeof b.weight !== 'number')) return '';
|
|
10078
|
+
const bindings = (row as StepBinding[]).filter((b) => b.weight > 0);
|
|
10079
|
+
const first = bindings[0];
|
|
10080
|
+
if (first === undefined) return '';
|
|
10081
|
+
const transform = transforms.get(first.bone);
|
|
10082
|
+
if (transform === undefined) return '';
|
|
10083
|
+
const rx = transform.a * first.x + transform.b * first.y + transform.worldX - context.stage.x;
|
|
10084
|
+
const ry = cropToSpineY(transform.c * first.x + transform.d * first.y + transform.worldY - context.stage.y, context.stage.height);
|
|
10085
|
+
const ux = Math.round(rx * GRID);
|
|
10086
|
+
const uy = Math.round(ry * GRID);
|
|
10087
|
+
if (!Number.isFinite(ux) || !Number.isFinite(uy) ||
|
|
10088
|
+
Math.abs(rx * GRID - ux) > CONTOUR_GRID_TOLERANCE || Math.abs(ry * GRID - uy) > CONTOUR_GRID_TOLERANCE) return '';
|
|
10089
|
+
vertices.push({ index: v, point: [ux / GRID, uy / GRID], bindings });
|
|
10090
|
+
}
|
|
10091
|
+
const explicitCount = mesh.contour.regions?.length ?? 0;
|
|
10092
|
+
const clauses: string[] = [];
|
|
10093
|
+
for (const [k, reg] of regions.entries()) {
|
|
10094
|
+
if (reg.band <= 0) continue;
|
|
10095
|
+
const sites = vertices.map((v) => ({ ...v, site: regionBandSite(v.point, reg), share: bandTargetShare(meshPart, reg.bone, v.bindings) }));
|
|
10096
|
+
if (!sites.some((s) => s.site === 'band' || s.site === 'cutoff')) continue;
|
|
10097
|
+
if (sites.some((s) => {
|
|
10098
|
+
if (s.site !== 'band' && s.site !== 'region') return false;
|
|
10099
|
+
const g = regionWeight(s.point, reg);
|
|
10100
|
+
const effective = k < explicitCount && reg.falloff !== 'linear' && g < 0.5 ? 4 * g * g * (1 - g) : g;
|
|
10101
|
+
return effective >= 1e-4 && s.share <= 0;
|
|
10102
|
+
})) continue;
|
|
10103
|
+
const atField = k < explicitCount ? `meshes.${meshPart}.contour.regions[${k}].band` : `meshes.${meshPart}.contour.bust`;
|
|
10104
|
+
const perVertex = sites.map((s) => `vertex ${s.index} is ${bandSiteLabel(s.site)} (share ${s.share})`).join(' and ');
|
|
10105
|
+
clauses.push(`contour band region "${reg.name}" (target bone "${reg.bone}", width ${reg.band} px at ${atField}): ${perVertex}, so the band's falloff governs this edge`);
|
|
10106
|
+
}
|
|
10107
|
+
return clauses.join('; ');
|
|
10108
|
+
}
|
|
10109
|
+
|
|
9977
10110
|
/** Recover only a replay that reproduces every written share on the named vertices. */
|
|
9978
10111
|
function weightCutReplay(rig: Record<string, unknown>, part: string, rows: ReadonlyMap<number, StepBinding[]>, context?: WeightStepContext): { raw: Map<number, Influence[]>; limits: InfluenceLimits } | null {
|
|
9979
10112
|
if (context?.config === undefined || context.stage === undefined) return null;
|
|
@@ -10182,10 +10315,11 @@ export function stretchLine(geo: IdleGeometry | null, path: string, problems: Pr
|
|
|
10182
10315
|
if (severity > TEXTURE_STRETCH_CEILING) {
|
|
10183
10316
|
failed = true;
|
|
10184
10317
|
const step = bound === undefined ? '' : weightStepText(bound.rig, m.slot, m.attachment, at.edge, bound);
|
|
10318
|
+
const band = bound === undefined ? '' : contourBandText(bound.rig, m.slot, m.attachment, at.edge, bound, slotParts);
|
|
10185
10319
|
problems.push({
|
|
10186
10320
|
code: 'CHECK_TEXTURE_STRETCH',
|
|
10187
10321
|
object: `mesh "${m.slot}" ${stretchAtText(at)}`,
|
|
10188
|
-
detail: `the edge is ${round3(at.ratio)} times its rest length (max(ratio, 1/ratio) ${severity}); <= ${TEXTURE_STRETCH_CEILING} is required${bound === undefined ? '' : `; ${edgeBonesText(bound.rig, bound.motion, m.slot, m.attachment, at.edge)}${step === '' ? '' : `; ${step}`}`} — the texture on it is ${at.ratio >= 1 ? 'stretched' : 'squeezed'}: the bones this mesh is weighted to move apart (amplitudes too large down a chain), or a vertex blends bones that move against each other`,
|
|
10322
|
+
detail: `the edge is ${round3(at.ratio)} times its rest length (max(ratio, 1/ratio) ${severity}); <= ${TEXTURE_STRETCH_CEILING} is required${bound === undefined ? '' : `; ${edgeBonesText(bound.rig, bound.motion, m.slot, m.attachment, at.edge)}${step === '' ? '' : `; ${step}`}${band === '' ? '' : `; ${band}`}`} — the texture on it is ${at.ratio >= 1 ? 'stretched' : 'squeezed'}: the bones this mesh is weighted to move apart (amplitudes too large down a chain), or a vertex blends bones that move against each other`,
|
|
10189
10323
|
});
|
|
10190
10324
|
}
|
|
10191
10325
|
}
|
package/src/localweights.ts
CHANGED
|
@@ -97,8 +97,12 @@ function onSegment(px: number, py: number, ax: number, ay: number, bx: number, b
|
|
|
97
97
|
return px >= Math.min(ax, bx) && px <= Math.max(ax, bx) && py >= Math.min(ay, by) && py <= Math.max(ay, by);
|
|
98
98
|
}
|
|
99
99
|
|
|
100
|
-
|
|
101
|
-
|
|
100
|
+
function compareBigInt(a: bigint, b: bigint): -1 | 0 | 1 {
|
|
101
|
+
return a < b ? -1 : a > b ? 1 : 0;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
/** Compare the squared distance from p to segment a–b against `r2`: -1 below, 0 equal, 1 above. Exact on integer units. */
|
|
105
|
+
function compareSegmentDistance2(px: number, py: number, ax: number, ay: number, bx: number, by: number, r2: bigint): -1 | 0 | 1 {
|
|
102
106
|
const dx = bx - ax;
|
|
103
107
|
const dy = by - ay;
|
|
104
108
|
const vx = px - ax;
|
|
@@ -106,10 +110,15 @@ function atLeast(px: number, py: number, ax: number, ay: number, bx: number, by:
|
|
|
106
110
|
const along = BigInt(vx) * BigInt(dx) + BigInt(vy) * BigInt(dy);
|
|
107
111
|
const len2 = BigInt(dx) * BigInt(dx) + BigInt(dy) * BigInt(dy);
|
|
108
112
|
const sq = (x: number, y: number): bigint => BigInt(x) * BigInt(x) + BigInt(y) * BigInt(y);
|
|
109
|
-
if (along <= 0n) return sq(vx, vy)
|
|
110
|
-
if (along >= len2) return sq(px - bx, py - by)
|
|
113
|
+
if (along <= 0n) return compareBigInt(sq(vx, vy), r2);
|
|
114
|
+
if (along >= len2) return compareBigInt(sq(px - bx, py - by), r2);
|
|
111
115
|
const cross = BigInt(dx) * BigInt(vy) - BigInt(dy) * BigInt(vx);
|
|
112
|
-
return cross * cross
|
|
116
|
+
return compareBigInt(cross * cross, r2 * len2);
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
/** Is the squared distance from p to a–b at least `r2`? Exact, integer units, `BigInt` where a product could pass 2^53. */
|
|
120
|
+
function atLeast(px: number, py: number, ax: number, ay: number, bx: number, by: number, r2: bigint): boolean {
|
|
121
|
+
return compareSegmentDistance2(px, py, ax, ay, bx, by, r2) >= 0;
|
|
113
122
|
}
|
|
114
123
|
|
|
115
124
|
/** Strictly inside the ring by the crossing rule, on integer units (a point on an edge is asked separately). */
|
|
@@ -123,6 +132,43 @@ function insideRing(px: number, py: number, xs: readonly number[], ys: readonly
|
|
|
123
132
|
return inside;
|
|
124
133
|
}
|
|
125
134
|
|
|
135
|
+
/** Where a 1/256 px grid point sits relative to `reg` and its declared falloff band: exact on integer units. */
|
|
136
|
+
export type RegionBandSite = 'region' | 'band' | 'cutoff' | 'outside';
|
|
137
|
+
|
|
138
|
+
/**
|
|
139
|
+
* Classify `p` against `reg` and its declared `band` (`0 < d < band` is `'band'`, `d === band` with `band > 0` is `'cutoff'`).
|
|
140
|
+
* `p` must lie on the 1/256 px grid, like every contour vertex {@link localInfluences} weights.
|
|
141
|
+
*/
|
|
142
|
+
export function regionBandSite(p: Point, reg: WeightRegion): RegionBandSite {
|
|
143
|
+
const px = units(p[0], 'point x');
|
|
144
|
+
const py = units(p[1], 'point y');
|
|
145
|
+
const B = units(reg.band, 'band');
|
|
146
|
+
if (reg.shape === 'circle') {
|
|
147
|
+
const dx = px - units(reg.cx, 'cx');
|
|
148
|
+
const dy = py - units(reg.cy, 'cy');
|
|
149
|
+
const R = units(reg.r, 'r');
|
|
150
|
+
const d2 = BigInt(dx) * BigInt(dx) + BigInt(dy) * BigInt(dy);
|
|
151
|
+
if (d2 <= BigInt(R) * BigInt(R)) return 'region';
|
|
152
|
+
if (B === 0) return 'outside';
|
|
153
|
+
const outer2 = BigInt(R + B) * BigInt(R + B);
|
|
154
|
+
return d2 < outer2 ? 'band' : d2 === outer2 ? 'cutoff' : 'outside';
|
|
155
|
+
}
|
|
156
|
+
const xs = reg.points.map((q) => units(q[0], 'polygon x'));
|
|
157
|
+
const ys = reg.points.map((q) => units(q[1], 'polygon y'));
|
|
158
|
+
const n = xs.length;
|
|
159
|
+
for (let i = 0; i < n; i++) if (onSegment(px, py, xs[i], ys[i], xs[(i + 1) % n], ys[(i + 1) % n])) return 'region';
|
|
160
|
+
if (insideRing(px, py, xs, ys)) return 'region';
|
|
161
|
+
if (B === 0) return 'outside';
|
|
162
|
+
const B2 = BigInt(B) * BigInt(B);
|
|
163
|
+
let atCutoff = false;
|
|
164
|
+
for (let i = 0; i < n; i++) {
|
|
165
|
+
const cmp = compareSegmentDistance2(px, py, xs[i], ys[i], xs[(i + 1) % n], ys[(i + 1) % n], B2);
|
|
166
|
+
if (cmp < 0) return 'band';
|
|
167
|
+
if (cmp === 0) atCutoff = true;
|
|
168
|
+
}
|
|
169
|
+
return atCutoff ? 'cutoff' : 'outside';
|
|
170
|
+
}
|
|
171
|
+
|
|
126
172
|
/**
|
|
127
173
|
* The nominal linear share at `p` (same frame as the region), used to decide
|
|
128
174
|
* support. `p` must be on the 1/256 px grid. See the module header for
|
package/src/runstamp.ts
CHANGED
|
@@ -36,7 +36,7 @@ export interface RunStampFileEntry {
|
|
|
36
36
|
sha256: string;
|
|
37
37
|
}
|
|
38
38
|
|
|
39
|
-
/** Compose's consumed inputs and
|
|
39
|
+
/** Compose's consumed inputs and placement, with the output profile recorded on success. */
|
|
40
40
|
export interface ComposeRun {
|
|
41
41
|
spec: typeof COMPOSE_RUN_SPEC;
|
|
42
42
|
scene: RunStampFileEntry;
|
|
@@ -52,6 +52,7 @@ export interface ComposeRun {
|
|
|
52
52
|
}>;
|
|
53
53
|
plate: RunStampFileEntry | null;
|
|
54
54
|
plates: Array<{ name: string; path: string; sha256: string }>;
|
|
55
|
+
output_profile?: 'preview' | 'no-extremes';
|
|
55
56
|
}
|
|
56
57
|
|
|
57
58
|
export interface RunStampInputEntry<Role extends string = RunStampInputRole> {
|
package/src/scene.ts
CHANGED
|
@@ -109,7 +109,7 @@ import { documentPageLookup, readModel, type ModelPageRegion } from '@rig-c/core
|
|
|
109
109
|
import { CandidateAtlasError, CandidatePairError, CoreInputError, loadCandidate, PoserChoiceError, projector, renderFrame, SpineRuntimeError, throughPoser, type Piece, type Quad, type Viewport } from '@rig-c/core/render-shared';
|
|
110
110
|
import { deformSliderCombinationProblem, type RigStop } from '@rig-c/core/rig';
|
|
111
111
|
import { checkStage, gateThroughRigc, type Log } from './build.ts';
|
|
112
|
-
import { ACCEPTABLE_BARS, barsNotMet, CHECK_SPEC, type CheckReport, DEFAULT_PACK_SHAPE, DEFAULT_PAGE_EDGES, IDLE_FPS, LOOP_SEAM_BAR_UNMET, type LoopSeamRequest, type PackMode, parsePageSize, requirementsNotPass, type RigcRunner } from './check.ts';
|
|
112
|
+
import { ACCEPTABLE_BARS, barsNotMet, CHECK_SPEC, type CheckReport, COMPOSE_PREVIEW_LOOP_SEAM_DETAIL, DEFAULT_PACK_SHAPE, DEFAULT_PAGE_EDGES, IDLE_FPS, LOOP_SEAM_BAR_UNMET, type LoopSeamRequest, type PackMode, parsePageSize, requirementsNotPass, type RigcRunner } from './check.ts';
|
|
113
113
|
import { CONSTRAINT_BONE_FIELDS, editorReceiptProblems, ROOT_BONE } from './config.ts';
|
|
114
114
|
import { cropToSpineY } from './coords.ts';
|
|
115
115
|
import { failLine, PartsError, type Problem, refuseIfAny } from './errors.ts';
|
|
@@ -2414,6 +2414,8 @@ export interface ComposeInput {
|
|
|
2414
2414
|
requirements?: string;
|
|
2415
2415
|
/** Declared RGBA loop seam bar and warm-up cap for the composed idle render (issue #1590). */
|
|
2416
2416
|
loopSeam?: LoopSeamRequest;
|
|
2417
|
+
/** The selected output profile, absent for the full diagnostics (issue #1610). */
|
|
2418
|
+
outputProfile?: ComposeRun['output_profile'];
|
|
2417
2419
|
/** `--accept`: the bars every character's own check may fail and still be composed (issue #203). */
|
|
2418
2420
|
accept?: readonly string[];
|
|
2419
2421
|
}
|
|
@@ -2434,6 +2436,17 @@ export interface ComposeResult {
|
|
|
2434
2436
|
check: CheckReport | null;
|
|
2435
2437
|
}
|
|
2436
2438
|
|
|
2439
|
+
/** Refuse before resolving rigc in the CLI, and before the gate for direct stage callers. */
|
|
2440
|
+
export function refusePreviewLoopSeam(input: ComposeInput): void {
|
|
2441
|
+
if (input.outputProfile !== 'preview' || input.loopSeam === undefined) return;
|
|
2442
|
+
for (const p of COMPOSE_OWNS) rmSync(join(input.out, p), { recursive: true, force: true });
|
|
2443
|
+
throw new PartsError([{
|
|
2444
|
+
code: 'COMPOSE_PREVIEW_REQUIRED_CHECK',
|
|
2445
|
+
object: '--loop-seam-bar',
|
|
2446
|
+
detail: COMPOSE_PREVIEW_LOOP_SEAM_DETAIL,
|
|
2447
|
+
}]);
|
|
2448
|
+
}
|
|
2449
|
+
|
|
2437
2450
|
/**
|
|
2438
2451
|
* Load the scene and every build, compose, gate the result through rig-c
|
|
2439
2452
|
* exactly as `rig` and `build` gate theirs ({@link gateThroughRigc}: `build
|
|
@@ -2461,6 +2474,11 @@ export function composeStage(input: ComposeInput, run: ComposeRunners, log: Log)
|
|
|
2461
2474
|
return { stoppedAt: stage, composed, check: null };
|
|
2462
2475
|
};
|
|
2463
2476
|
const pageSize = parsePageSize(input.pageSize);
|
|
2477
|
+
try {
|
|
2478
|
+
refusePreviewLoopSeam(input);
|
|
2479
|
+
} catch (err) {
|
|
2480
|
+
return refused('compose', err);
|
|
2481
|
+
}
|
|
2464
2482
|
mkdirSync(input.out, { recursive: true });
|
|
2465
2483
|
for (const p of COMPOSE_OWNS) rmSync(join(input.out, p), { recursive: true, force: true });
|
|
2466
2484
|
const mode: PackMode = { pageEdges: DEFAULT_PAGE_EDGES, packShape: DEFAULT_PACK_SHAPE, ...(pageSize === undefined ? {} : { pageSize }) };
|
|
@@ -2559,9 +2577,9 @@ export function composeStage(input: ComposeInput, run: ComposeRunners, log: Log)
|
|
|
2559
2577
|
writeFileSync(reportPath, rigJsonText(r));
|
|
2560
2578
|
say(`${wroteRig}, and ${reportPath}`);
|
|
2561
2579
|
}
|
|
2580
|
+
const stage = r.characters.some(c => c.canvas_clip === true) ? composed.rig.skeleton : undefined;
|
|
2562
2581
|
let checkRigc = run.check;
|
|
2563
|
-
if (
|
|
2564
|
-
const stage = composed.rig.skeleton;
|
|
2582
|
+
if (stage !== undefined) {
|
|
2565
2583
|
const viewport = [stage.x, stage.y, stage.width, stage.height].join(',');
|
|
2566
2584
|
checkRigc = args => run.check(args[0] === 'render' && !args.includes('--viewport') && !args.includes('--viewport-from')
|
|
2567
2585
|
? [...args, '--viewport', viewport]
|
|
@@ -2592,6 +2610,14 @@ export function composeStage(input: ComposeInput, run: ComposeRunners, log: Log)
|
|
|
2592
2610
|
writeFileSync(reportPath, rigJsonText(composed.report));
|
|
2593
2611
|
say(`${wroteRig}, and ${reportPath}`);
|
|
2594
2612
|
};
|
|
2613
|
+
const preview = input.outputProfile === 'preview';
|
|
2614
|
+
const noExtremes = input.outputProfile !== undefined;
|
|
2615
|
+
const checkLog = prefix('check');
|
|
2616
|
+
if (noExtremes) {
|
|
2617
|
+
const flag = preview ? '--output-profile preview' : '--no-extremes';
|
|
2618
|
+
checkLog(` extremes: SKIP — ${flag} omits the extra diagnostic renders`);
|
|
2619
|
+
}
|
|
2620
|
+
if (preview) checkLog(' idle diagnostics: SKIP — --output-profile preview omits idle_frames/, contact.png and motion_heat.png');
|
|
2595
2621
|
let report: CheckReport;
|
|
2596
2622
|
try {
|
|
2597
2623
|
report = checkStage({
|
|
@@ -2599,7 +2625,9 @@ export function composeStage(input: ComposeInput, run: ComposeRunners, log: Log)
|
|
|
2599
2625
|
...(pageSize === undefined ? {} : { pageSize }),
|
|
2600
2626
|
...(input.requirements === undefined ? {} : { requirements: input.requirements }),
|
|
2601
2627
|
...(input.loopSeam === undefined ? {} : { loopSeam: input.loopSeam }),
|
|
2602
|
-
|
|
2628
|
+
...(noExtremes ? { noExtremes: true } : {}),
|
|
2629
|
+
...(preview ? { previewIdle: true } : {}),
|
|
2630
|
+
}, checkRigc, run.checkBin, checkLog);
|
|
2603
2631
|
} catch (err) {
|
|
2604
2632
|
if (cameraBindingFailed) {
|
|
2605
2633
|
for (const p of COMPOSE_OWNS) rmSync(join(input.out, p), { recursive: true, force: true });
|
|
@@ -2625,8 +2653,10 @@ export function composeStage(input: ComposeInput, run: ComposeRunners, log: Log)
|
|
|
2625
2653
|
log(`compose: stopped at check; the composed rig's check is PASS${acceptedLine} (the composed rig and scene.json are written; the scene is for looking, not shipping)`);
|
|
2626
2654
|
return { stoppedAt: 'check', composed, check: report };
|
|
2627
2655
|
}
|
|
2628
|
-
|
|
2629
|
-
|
|
2656
|
+
const runRecord = input.outputProfile === undefined ? composed.runRecord : { ...composed.runRecord, output_profile: input.outputProfile };
|
|
2657
|
+
writeFileSync(join(input.out, COMPOSE_RUN_FILE), rigJsonText(runRecord));
|
|
2658
|
+
const verdict = preview ? 'PREVIEW — checks met;' : noExtremes ? 'NO EXTREMES — checks met;' : 'PASS —';
|
|
2659
|
+
log(`compose: ${verdict} ${report.bars.measured.length} of ${report.bars.measured.length + report.bars.skipped.length} bar(s) measured; the packed atlas under ${join(input.out, 'check', 'build')} is the artifact`);
|
|
2630
2660
|
return { stoppedAt: null, composed, check: report };
|
|
2631
2661
|
}
|
|
2632
2662
|
|