animation.md repeated the whole `MoVE` state-machine section, gbuffer.md
repeated the `OSG1` census table and section 2 (leaving a `## 3` heading whose
body began mid-sentence), and testing.md repeated the 128-byte push-constant
section back to back after a list item. The copy dropped in each page is the
older one: the surviving `MoVE` text adds "747 child states total" and the
surviving `### Arithmetic` text carries the 256-of-256 / 2-of-256 round trip.
🤖 Generated with Codebuff
Co-Authored-By: Codebuff <noreply@codebuff.com>
Squash-merged after review of PR #4881 - anim_clips: count clip windows; the clip timing rule over all 785,174 entries (was 4,471 in 300 sampled dictionaries)
From @ismailchaka1's check on #3341: types 4-8 have a {ptr, count} array at
+0x20 (null on type 4 and on 431 of 482 type-5 nodes; on every type-6/8 node,
items {u32, 0, u32, 0}). Counted as motion_node_pairs:<type>:<count|null> and
documented; the values are not decoded. Rechecked on anim.rpf.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- shader_disasm: prune stale listings against every input, not the --skip-existing remainder (a resumed run
deleted every listing it had just reused).
- progress_dashboard: a drive-letter path is never inside the repository off Windows (it printed user names);
its own read_text helper is read_utf8, so the encoding check does not take it for pathlib's.
- Translator tests follow this round's rules: desc_lookup's BroadcastFirst in the typed-load condition walker;
resinfo sizes are 0 past the last level and a 2D depth word is 0 (SHADER-388); SHADER-315 constant folding in
the perm and i16 tests; #2089's structured wave64 emulation.
- test_semantic_translator_use: 57 oracle-only files merged before it are DEBT; test_spirv_tools_required is
allowed (CI meta-test).
- Test fixes: image_fuzz fake writes the programs, preflight follows c506d00c's loader hint rule, feature_scan
reads the first line of a pytest-decorated message, w64_graphics wording.
- docs: rows merged again in design.md, README.md, d3d12_vulkan.md; GameInput table rebuilt from #3172's rows;
orphan rows in models.md and embedded_shaders.md; repeated bullets; anchors; a flag not on main.
- Repo rules: stdout guard on 14 programs; LF writes; csv lineterminator in bink_play.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Parameter node types 3, 4, 5, 6 and 8 carry 1-5 axes ({u32 name hash, u16,
u16} at +0x10); types 4/5/6/8 keep their sample count at +0x90/+0x90/+0x50/
+0xA0, type 1 at +0x20. The .motion's +0x90 lists (one per node sample,
items {u32 child, f32, f32}) map each sample to a child: checked on all
8,932 one-node motions in anim.rpf. Counts only; synthetic tests.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
docs/animation.md said the bone names in anim.rpf's four bone-table streams
could not be matched to a skeleton, because the pages carry no model name and
the model manifest no bone names. A skeleton carries its own names, though
(joaat32 at bone record +0x1C, name at +0x30). The new tool reads the names out
of the four streams and every skeleton anim_glb reads in packs.rpf, and counts
matches by joaat32 of the lowercased name.
On the 1.0.2.1 package: all 30 names are joints, all with the same spelling;
only the 596-bone female and 560-bone male humanoid skeletons hold every one
(14,212 skeletons, 199 distinct); the 15-name table is shared by 69 distinct
smaller rigs. animation.md records the counts.
- tests/semantic: BaseVertex/BaseInstance read 0 in the wave interpreter; the LDS MockGens follow
SHADER-309 (lds_bound, lds_access, lds_atomic); abs emission tests load their operand, since
SHADER-315 folds scalar ALU on constants.
- test_translate: the dynamic gather sampler is a loaded word, not s16 + 0 (SHADER-315 folds it).
- test_world_build: DDS downscale weights colours by alpha (62804d0d).
- test_fspx_shaders_stage: the fake disassembler writes the listing make_game now checks.
- xgameruntime_test: re-read the package id after clearing the LEONIDA_PACKAGE_ID override.
- docs: one row per topic again in design.md (72 topics) and README.md; one Other languages line;
embedded_shaders.md keeps one copy of each bullet; animation.md links the heading anchor.
- tools/scripts: character_textures uses report_paths.same_report_path; stdout guard on six programs;
LF write in vs_input_survey; the cl.exe fallback compiles winhttp_offline.cpp.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
tools/anim_glb.py reads a fragment's skeleton (drawable +0x18: bone records,
inverse bind matrices, parents), binds part meshes to it through the model
bone list at grmModel+0x28 (ASSET-12 skin layouts), and writes decoded
anim.rpf clips as glTF animations: bonerotation/bonetranslation/bonescale
drive the joint with the track's bone hash, bone hash 0 drives a mover node,
and a clip entry maps animation time t to (t - start) / rate. --coverage
counts how many clip bone tracks name a skeleton joint.
docs/character_skeleton.md: the instance table was read 0x40 bytes late, so
each row paired a bone with the next bone's TRS. Read from the record start,
the default transforms compose to the stored inverse bind matrices (5.1e-6 m
female, 3.3e-6 m male, all 14,212 skeletons in packs.rpf within 1e-3). The
model bone list is at +0x28, not +0x20. New "Animated glTF export" section
with the measured counts; animation.md, models.md, character_models.md and
the docs index follow.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The rig dictionaries share the clip dictionary root; each map value points at +0x20 to a RIG block of
{kind, size, count, word} tables. Their names are the RBF0 sources, and all 6,677 rig-set entries resolve
to a key there. docs/animation.md gets the layout, the counts and the clip-to-skeleton measurement.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
.motion +0x70 holds one 0x28-byte item per child: the child's duration, its
duration in the blend and a (child time, blend time) curve. On anim.rpf the
first float is bit-for-bit the named .clip's duration for all 111,948 children
that name a .clip there; 158,991 of 159,584 curves are the identity and 402 are
monotonic time warps.
The parameter node is at +0x138 (+0x58 = 1) or at +0x18 of the block +0x120
points at (+0x58 = 2). Type 3 (10,171 of 17,247) is one sampled axis: a name
hash, (sample index, value) items sorted by value, min and max. 10 of the 88
axis name hashes resolve to joaat32 names such as yawangle and speed.
Also documents that the unlisted-last-page recovery needs the page map in a
listed stream (whattheflop's review on #1174): no anim.rpf root and no
story000 clip dictionary has its page map in such a tail. A synthetic test
keeps that layout unresolved.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The 36 roots whose second system page is not the next listed stream have it
right after the first stream: a zlib stream inflating to 16-48 bytes, which
anim_index.py does not list (it keeps streams of 64 bytes or more), or a
16-byte raw page. group() now tries that page and joins it only when the
pages parse as a clip dictionary. All 36 join; 191,042 animations decode.
.motion clips list their children as {u64 0; u32 clip hash; u32 dictionary
hash} at +0x60, and the root's hash-only +0x70 references are dictionary
hashes. scan() joins both across the archive: 111,948 of the 114,925
children whose dictionary is in anim.rpf name a .clip of it.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
tools/anim_clips.py groups the stream walk of anim_index.py into RAGE
resources via the page map at the +0x08 pointer, finds the clip
dictionaries (system-only, 1 or 2 pages) and decodes dictionary -> clips
-> packs -> animations -> sequences -> channels. Channel types 0-5, 7, 8
and the GTA VI type 10 (second-order delta coding) are decoded. Output is
counts and per-dictionary rows only; --decode prints one dictionary's
values to stdout for local use.
docs/animation.md gets a "Keyframe decoding" section with the layouts and
the measured full-archive counts, and the statements it makes stale are
updated: 0x98e1750c is joaat32("bonerotation"), the 2/3 packed streams
are second system pages of 0DRP resources, and keyframes are decoded for
the clip dictionaries. tests/test_anim_clips.py builds synthetic
resources, including a type-10 encoder for a round trip.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Fresh scan/recover at the new pin, no cache, across every model-bearing archive. The new pin recovers 350,248 models (159,483 drawable-dictionary children) against 190,792 at c3708fb.
Per archive: levels.rpf 314,000 (130,225 children), story000 7,460 (4,156), packs 24,034 (23,720), data 2,581 (268), shared_minigame000 1,288 (317), core_restofworld 885 (797). The standalone total is 190,765, 27 below the c3708fb recovery (duplicates merged). levels.rpf is the sum of ten parallel recovery shards over 206,981 candidates; the last shard rejects 1,009 incomplete/duplicate tail pages. Triangle totals and the C# TTPF texture counts were not re-run.
Add a character-skeleton page: 597-name #ft table, the following 597-record parent/reference-TRS table, the model bone-hash mapping, and the character material texture-parameter split. Update animation.md with the partial clip decode (two named clips, 0x48-byte track arrays, 63/38 and 12/38 masks) and the 46-byte MoVE header correction. Link the new page from models.md and design.md. No game data.
Adds the #283 argparse validators to anim_index, rbf0_index, restofworld_index and rpf9_carve: --start >= 0, --limit >= 1 (decimal or 0x hex), and --max-inflate >= 1 in restofworld_index. Bad ranges now exit 2 before any scan or output instead of silently scanning everything, less, or nothing. Synthetic CLI tests in all four test files; docs notes for each tool.
New item claimed in #156. AI-assisted (OpenCode).
Add a stdlib record/tree decoder for the measured RBF0 format. It joins 64 KiB continuations, parses the inline descriptor table, builds element/attribute/content/text trees, and writes JSON plus optional generic XML. Unknown descriptors, record types and malformed framing fail closed with a partial tree. Add synthetic tests and the measured grammar, samples and remaining unknowns to docs/rbf0.md; note the rig-set blob tree result in docs/animation.md.