upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorItsNotRexed <300290919+ItsNotRexed@users.noreply.github.com>2026-11-22 00:33:14 -0500
committerItsNotRexed <300290919+ItsNotRexed@users.noreply.github.com>2026-11-22 00:33:14 -0500
commitcd5a8c484bd6b9ca7206274d10afd2cf2a11491f (patch)
tree047e3c402b01c74e3a07360fa4808b483ff1b9f0 /docs
parent81647000ccdd0b94cf972ed8a85578014505bf93 (diff)
parent3bce1fd0d0548e2436a091e173596e40c1fcc8fd (diff)
Merge pull request #951 from Lucy
Diffstat (limited to 'docs')
-rw-r--r--docs/textures.md35
1 files changed, 35 insertions, 0 deletions
diff --git a/docs/textures.md b/docs/textures.md
index 6bddabe5c..c9f449f43 100644
--- a/docs/textures.md
+++ b/docs/textures.md
@@ -481,6 +481,41 @@ entry. Exporters must **not** fall back to the first texture in that case; a nor
481as a base colour is the usual symptom. The hashes are treated as measured corpus semantics, not 481as a base colour is the usual symptom. The hashes are treated as measured corpus semantics, not
482as a claim that they are globally unique across every shader. 482as a claim that they are globally unique across every shader.
483 483
484### Map material texture parameters
485
486The character table above covers 246 records. Map drawables (buildings, roads, terrain, props) use more
487parameters. Five more names come from the case-sensitive joaat of the parameter name, the same check that
488names `0xC8E8C282` (`diffusetex`) in rpf9-explorer's `ModelTextureBindings`:
489
490| Parameter | Name (joaat) |
491|---|---|
492| `0x1E77BF4C` | `bumptex` |
493| `0xC6F46E79` | `speculartex` |
494| `0x739E3D0D` | `speculartex2` |
495| `0x3FB7964F` | `tinttexture` |
496| `0xC075F9B6` | `lookuptexture` (terrain materials) |
497
498Content check on map drawables: a random sample of 1,500 `.ydr`/`.yft` models (seed 7), each referenced
499texture counted once per parameter. A texture is "normal-map-like" when its mean colour (BC1 colour-0
500endpoints, BC7 mode-6 endpoints) has blue > 190 and red and green within 45 of 128; BC5 is two-channel.
501
502| Parameter | Normal-map-like | Not normal-like | BC5 | Formats (DXGI: count) |
503|---|---:|---:|---:|---|
504| `0x1E77BF4C` `bumptex` | 1,394 | 74 | 131 | 71: 1,659, 83: 131, 98: 106 |
505| `0xC6F46E79` `speculartex` | 69 | 1,469 | 0 | 71: 1,650, 98: 372, 28: 4 |
506| `0x739E3D0D` `speculartex2` | 5 | 851 | 0 | 98: 738, 71: 225, 72: 1 |
507| `0xC8E8C282` `diffusetex` | 28 | 1,887 | 0 | 72: 1,322, 99: 709, 78: 145 |
508| `0x3FB7964F` `tinttexture` | 0 | 61 | 0 | 72: 61, 99: 2, 78: 1 |
509
510So on map materials `bumptex` is the tangent-space normal map and `speculartex` is not a normal map. The
511character table above lists `0xC6F46E79` as the normal map; these character textures are mostly outside the
512measured catalog here, so that row is left unchanged, but it should be re-checked against the name.
513
514Three more parameters hold sRGB colour-like textures on map materials and are not in `ModelTextureBindings`
515(names not found): `0x17D3B5C2` (72: 47), `0x6994EF3F` (99: 25) and `0x7485DAFB` (99: 162, 78: 15, 72: 12;
516a tiling detail layer next to the two-layer `lyr0diffusetex`/`lyr1diffusetex` blend). `tinttexture` holds an
517ID/palette map on most materials and is not a base colour outside terrain.
518
484## BCPack block structure and limits 519## BCPack block structure and limits
485 520
486A BCPack chunk is not a self-describing container. The container gives it a decoded (virtual) 521A BCPack chunk is not a self-describing container. The container gives it a decoded (virtual)