@dcl/abgen-win32-x64 0.17.13 → 0.19.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/BUILD-INFO.txt CHANGED
@@ -1,6 +1,6 @@
1
- ABGEN_VERSION=0.17.13
2
- ABGEN_RELEASE=v0.17.13
1
+ ABGEN_VERSION=0.19.0
2
+ ABGEN_RELEASE=v0.19.0
3
3
  ABGEN_TARGET=x86_64-pc-windows-gnu
4
- ABGEN_BUILD_ID=c7f413c2a0a5
5
- ABGEN_GIT_REV=2230291c5eedebff9b249d60bf70b857cb25568a
4
+ ABGEN_BUILD_ID=96b6cff855db
5
+ ABGEN_GIT_REV=7324c4aecc2998ee377d32b1e93b4008629dfae1
6
6
  SOURCE_DATE_EPOCH=315532800
package/README.md CHANGED
@@ -13,7 +13,7 @@ resolves it for embedding tools - see [npm/abgen](npm/abgen/README.md)). From so
13
13
  ```bash
14
14
  git clone <this-repo> abgen && cd abgen
15
15
  cargo build --release # no postgres, no openssl, no protobuf
16
- cargo build --release --examples # bundle dump tools (objdump/texdump/matdump/texcmp/texpng)
16
+ cargo build --release --examples # bundle dump tools (objdump/texdump/matdump)
17
17
  scripts/bootstrap-runtime.sh # integrity-check the vendored runtime data
18
18
  ```
19
19
  There is also a wasm build: `crate/abgen-wasm/` compiles the converter to wasm32 — see its README.
@@ -26,10 +26,10 @@ There is also a wasm build: `crate/abgen-wasm/` compiles the converter to wasm32
26
26
  | `abgen-build` | single-file local converter CLI (glb -> bundle, `--expect-hash` verify) |
27
27
  | `abgen-corpus` | batch corpus builder: manifest / `--entity-ids` (add `--fetch-missing` to pull content from a catalyst) / `--world <name>[,...]` (resolve + fetch + convert a world; upstream via `--worlds-url` or `ABGEN_WORLDS_URL`) / `--live-mode` / `--collection-urn` / `--from-reference`; full-corpus runbook in [docs/BATCH.md](docs/BATCH.md) |
28
28
  | `abgen-verify` | parity differ (ours vs reference bundles, ppm-bits, `--tolerant`) |
29
- | `abgen-lod` | LOD lane CLI: `bundle`, `compare`, `placements`, `assemble`, `atlas`, `simplify`, `generate` |
29
+ | `abgen-lod` | LOD lane CLI: `bundle`, `placements`, `assemble`, `atlas`, `simplify`, `generate`, `compare` (structural diff of two LOD bundles: materials/textures/vertices/triangles plus a per-material property diff — shader, keywords, render queue, floats, clipping colours, texture bindings; local or CDN URL), `qualify-corpus` (Genesis City + Worlds corpus build; `--reference-cdn` records the same diff against production per scene) |
30
30
  | `abgen-lambda` | AWS Lambda handler (deployment event in, bundles + manifests to S3; from the `lambda/` workspace member) - see [lambda/README.md](lambda/README.md) |
31
31
 
32
- Plus bundle-inspection examples (`texdump`, `matdump`, `objdump`, `texcmp`, `texpng`) under
32
+ Plus bundle-inspection examples (`texdump`, `matdump`, `objdump`) under
33
33
  `target/release/examples/`.
34
34
  ## Server
35
35
  ```bash
@@ -59,6 +59,9 @@ header semantics, and the DB-vs-proxy source selection: [docs/ROUTES.md](docs/RO
59
59
  ABGEN_ROOT="$PWD" cargo test --workspace --lib -- --test-threads=1
60
60
  ```
61
61
  `--test-threads=1` is required: the lib tests share process-wide `ABGEN_ROOT` state.
62
+ LOD assembly frame conformance against the production `_1.glb` references: `cargo test --release
63
+ --test lod_handedness` (offline fixtures; add `-- --ignored` to assemble from the catalyst).
64
+
62
65
  ## wasm
63
66
  `crate/abgen-wasm/` compiles the converter lib (default features off) to `wasm32-unknown-unknown` behind
64
67
  a hand-rolled C ABI; the JS runtime in `crate/abgen-wasm/js/` (worker pool + WebGPU bridge) is what a
@@ -71,20 +74,17 @@ template paths in `crate/src/builder/templates.rs` assume the source layout wher
71
74
  the crate — an in-repo wasm32 build needs those relative paths bumped one level (`../../template/` ->
72
75
  `../../../template/`). No workspace target compiles for wasm32, so the divergence never touches CI.
73
76
  ## Features
74
- One compile-time feature flag: `server` (on by default) gates the abcdn HTTP server + registry stack
75
- (axum/tokio/sqlx and the `dcl-contents` crate); the `abgen` bin has `required-features = ["server"]`.
76
- Library consumers - `lambda/`, `crate/abgen-native/`, `crate/abgen-wasm/` - build with
77
- `default-features = false` and get the converter without the server stack. Under the default
78
- features every capability below builds into every native binary; `wasm32` builds target-gate the
79
- server, content-DB, and GPU code off automatically. Each capability is activated at runtime, not at
80
- build time.
81
-
82
- | Capability | Built | Enable at runtime |
77
+ The default `server` feature builds the complete service. Reusable consumers should select only the lanes they need; the smallest native converter is `cargo build --release --lib --no-default-features`.
78
+
79
+ | Feature | Adds | Enabled by |
83
80
  |---|---|---|
84
- | tokio/axum HTTP JIT server (`abcdn` module + `abgen` bin) | always (native targets) | run the `abgen` bin |
85
- | catalyst content-DB index (sqlx/postgres, via the in-tree `dcl-contents` crate) for real timestamps + deployer on `/entities/*` and the unsigned registry routes (`/profiles*`, `/entities/status/{id}`, `/worlds/{name}/manifest`) | always | set a content-DB connection (`CONTENT_PG_CONNECTION_STRING` or `POSTGRES_CONTENT_*`); without one the built-in content-client fallback serves the index routes with `timestamp: 0`, empty deployer, and the registry routes proxy the upstream catalyst |
86
- | CUDA GPU BC7/BC5 encode path (`libcuda` dlopen'd at runtime, no toolkit needed to build; PTX kernels vendored in `crate/src/gpu/kernel.ptx`, regen from `crate/kernel-ptx/`) | always | opt in per run with `--gpu` / `ABGEN_GPU=1`, backend pick via `ABGEN_GPU_BACKEND=auto\|cuda\|wgpu\|off` |
87
- | portable `wgpu` compute backend (Vulkan/Metal/DX12), same dispatch + qualification gate | always | `ABGEN_GPU_BACKEND=wgpu` (or `auto`, which tries CUDA first) |
81
+ | `server` (default) | HTTP/registry stack, `gpu`, `cli`, `web-pack`, and `scene-runtime` | `abgen` server |
82
+ | `gpu` | native wgpu/CUDA dispatch | server, build/corpus/verify CLIs, Lambda |
83
+ | `web-pack` | BV WebGPU pack emission plus DDS/glTF JSON dependencies | server, build/corpus CLIs |
84
+ | `scene-runtime` | embedded QuickJS fallback for suspicious static LOD placements | server, LOD CLI, Lambda |
85
+ | `cli` | tracing subscriber and CLI logging | server and LOD CLI |
86
+
87
+ `crate/abgen-native`, `crate/abgen-node`, and converter WASM use no default features. The standalone `crate/wasm-gpu` package compiles the shared BC7/WebGPU source directly and does not depend on the full `abgen` graph; its worker ships only `gpu_init` and `gpu_encode`. Static CRDT placement interpretation remains available without `scene-runtime`; if that result is empty or suspicious, the minimal build fails explicitly instead of publishing an empty LOD.
88
88
 
89
89
  GPU backends self-qualify per device at enable time: the selected backend (`auto` tries CUDA, then
90
90
  wgpu) must reproduce the CPU BC7 encoder bit-for-bit on a probe matrix (sizes x srgb x perceptual x
@@ -131,6 +131,7 @@ restore it - it never fetches or re-downloads:
131
131
  | `ABGEN_JIT_FAIL_TTL_S` | `60` | failure negative-cache TTL for entity JIT builds; concurrent identical requests single-flight per `{entity}:{platform}` |
132
132
  | `ABGEN_JIT_CONTENT_DIGEST` | `0` | freshness for content servers whose declared hashes are not content-addressed (the `@dcl/sdk-commands` preview server keys them by file path). Defaults to ON when `ABGEN_CATALYST_URL` points at a loopback host (a dev preview server), OFF otherwise; explicit values always win. When on, manifest requests re-download the entity's convertible content, sha256 it, and prune stale conversions when bytes changed under an unchanged hash. Changed non-glb files (textures/`.bin`) also invalidate every glb bundle of the entity. Debounced per entity via `ABGEN_REVALIDATE_DEBOUNCE_S` (default `2`) |
133
133
  | `ABGEN_UPSTREAM_AB_CDN` | unset | read-through to a production ab-cdn (e.g. `https://ab-cdn.decentraland.org`): manifest/bundle/LOD/ISS requests that 404 through every local and JIT lane are streamed from upstream without persisting anything locally. Lets a client point its whole optimized-assets base URL here (wearables/emotes keep working) while only local scene entities are built locally. Paths containing `b64-` preview ids are never proxied |
134
+ | `ABGEN_UPSTREAM_AB_REGISTRY` | see right | upstream registry URL: records for entities without local bundles are answered with its versions. Default: `asset-bundle-registry.<domain>` when the CDN is `ab-cdn.<domain>`. `off` disables |
134
135
  | `RUST_LOG` | `abgen=info,tower_http=info` | tracing filter |
135
136
  | `CONTENT_PG_CONNECTION_STRING` (or `POSTGRES_*` parts) | unset | content DB; URL form also mounts the signed registry routes |
136
137
  ### S3 space cache (read-through + write-back)
@@ -147,8 +148,7 @@ Uploads carry each key family's production writer's object metadata, derived fro
147
148
  (cdn-uploader's comma-joined spelling), scene sources (`.js`/`.json`/`.crdt`) the direct-upload
148
149
  spelling `public, max-age=31536000, immutable`, manifests (`manifest/…`) `application/json` +
149
150
  `private, max-age=0, no-cache`, ISS descriptors (`lods-unity/manifests/…`)
150
- `public, max-age=31536000` (lod-generator-unity's spelling), `.br` keys
151
- `public,no-transform,max-age=31536000,immutable` + `Content-Encoding: br` (as cdn-uploader sets).
151
+ `public, max-age=31536000` (lod-generator-unity's spelling).
152
152
 
153
153
  ### Asset-reuse mode (upstream converter parity)
154
154
  ON by default, matching the ab-cdn deployment's asset-reuse naming from v49 onward: scene
@@ -168,6 +168,79 @@ non-digest names).
168
168
  `ABGEN_MAGENTA_MISSING` is on, in which case unresolvable deps are dropped from the digest and
169
169
  the build substitutes placeholder textures
170
170
 
171
+ ### Two version lanes: `AB_VERSION` and `WEARABLE_AB_VERSION`
172
+ Scene bundles and wearable/emote bundles live under separate key prefixes. `AB_VERSION` is the scene
173
+ lane; `WEARABLE_AB_VERSION` is wearables and emotes, and defaults to `AB_VERSION` when unset — so a
174
+ deployment that does not set it behaves exactly as it did when the two shared one prefix.
175
+
176
+ They are split because only a scene's name can carry an invalidation. Scene bundles are digest-named
177
+ (`{hash}_{digest}_{platform}`), so a dependency change or a recipe bump moves them; wearable bundles
178
+ are `{hash}_{platform}`, with nowhere to put one, which leaves the prefix as the only lever they
179
+ have. Sharing one prefix therefore meant every scene-driven bump dragged the whole wearable corpus
180
+ through a rebuild it had no use for, and every wearable-driven bump did the same to the world.
181
+
182
+ - The conversion path resolves its lane from the entity type (`Proxy::version_for`); everything
183
+ that is not a scene rides the wearable lane.
184
+ - The serving path has only a bundle name to go on, so it reads both lanes and then
185
+ `ABGEN_FALLBACK_VERSION` (`Proxy::read_versions`). Safe rather than merely convenient: an
186
+ entity's bundles exist under exactly one prefix and every name is content-addressed, so a hit is
187
+ the right bytes whichever lane answered. A miss costs one extra 404.
188
+ - The lambda's already-converted gate accepts a manifest at *either* lane, because the entity type
189
+ is only known after the entity doc is fetched and the gate deliberately runs before that. Safe
190
+ while the two are distinct strings: a manifest carries whichever version wrote it, so a bump of
191
+ either stops matching.
192
+
193
+ ### Per-asset-type cache keys (recipes)
194
+ `AB_VERSION` prefixes every space key, so bumping it orphans every bundle of every type at once —
195
+ the right hammer for a change to the bundle container, far too big for the usual fix, which changes
196
+ how one kind of asset is built and leaves the rest byte-identical. Baking skinned-renderer bounds
197
+ over the animation clips (#119) rewrote nothing but animated rigs; an `AB_VERSION` bump behind it
198
+ would have rebuilt every texture in the world.
199
+
200
+ `crate/src/recipes.rs` holds a generation counter per build-affecting behaviour and folds the ones
201
+ an asset uses into the digest that names its bundle. A bundle is rebuilt whole or not at all — a GLB
202
+ bundle carries its meshes, skeleton, clips, materials *and* its resolved textures in one artifact —
203
+ so there are only two base recipes, one per kind of bundle, plus two narrowing ones that earn their
204
+ place by being rare:
205
+
206
+ | Recipe | Applies to | Rebuilds on a bump |
207
+ |---|---|---|
208
+ | `glb` | every glTF | every glb bundle; no standalone image bundles |
209
+ | `texture` | standalone images, and any glTF with `images` | every image bundle **and** every glb that embeds one |
210
+ | `skin` | a glTF declaring `skins` | only rigs — a minority of glbs |
211
+ | `animation` | a glTF carrying `animations` | only animated glbs — a minority |
212
+
213
+ **To ship a fix without an `AB_VERSION` bump:** raise the matching counter by one, in the commit that
214
+ changes the output, then re-enqueue as you would for a version bump. Bundles whose recipes moved get
215
+ new names, miss the HEAD probe and rebuild; every other bundle keeps its name and is reused where it
216
+ already sits. Never renumber a counter and never reuse a value — a generation that comes back around
217
+ makes stale bundles look fresh.
218
+
219
+ Default to `glb`. Reach for `skin` or `animation` only when the fix has a gate you can point at —
220
+ #119 is the model, where a glTF with no clips serialized byte for byte as before. The asymmetry is
221
+ the whole rule: too broad costs a rebuild you were going to pay anyway, too narrow ships stale
222
+ bundles and says nothing. There is deliberately no counter per sub-asset (`mesh`, `material`) — the
223
+ bundle is the unit, so those would rebuild the same set `glb` does — and none for normal maps, since
224
+ "is this encoder fix normal-only?" is exactly the ambiguous question a recipe must not ask.
225
+
226
+ Scope and cost:
227
+ - Only the digest-named lane carries recipes. Wearables and emotes are `{hash}_{platform}`, with
228
+ nowhere to put a generation, so a fix to those still needs `AB_VERSION` — as does anything that
229
+ changes the bundle container, the manifest shape, or the client's side of the contract.
230
+ - Generation `0` folds in as nothing *in a digest*, so adopting this cost no rebuild: every
231
+ bundle name is byte-for-byte what it was before. Manifests do gain a `recipes` key.
232
+ - `AB_VERSION` stays total. It is the key prefix, never a digest input, and the conversion gate
233
+ gained a conjunct rather than a substitute, so a version bump still reconverts everything.
234
+ - Each conversion records, in the per-platform manifest's `recipes` block, every recipe governing
235
+ its bundles and the generation each stood at — **baselines included** — and `platform_converted`
236
+ compares it, so the lambda's already-converted skip stays correct without a `force` flag. A scene
237
+ of static props records `{"glb":0,"texture":0}`: bumping `skin` leaves it current (that is the
238
+ saving), bumping `glb` does not. Recording only the *bumped* recipes would be blind to every
239
+ later `0 -> 1` bump, which is why the baselines are kept here and dropped in the digest.
240
+ A manifest predating recipes has no block at all and reconverts once.
241
+ - The LOD lane solves the same problem with one counter of its own,
242
+ `crate/src/lodgen/pipeline.rs::LOD_GENERATION`, folded into the reuse state document.
243
+
171
244
  Display-only files — `autogenerated-thumbnail.png` anywhere in the content map, and whatever
172
245
  `metadata.display.navmapThumbnail` points at — are dropped from the conversion input, matching the
173
246
  prod converter's `-skippedHashes` flag: no bundle, no manifest entry, and no contribution to the
@@ -181,12 +254,17 @@ request waits up to the deadline, builds finish in the background. Knobs: `ABGEN
181
254
  `ABGEN_INDEX_BUILD_CONCURRENCY` (default: CPU count), `ABGEN_INDEX_BUILD_DEADLINE_MS` (default
182
255
  `20000`), `ABGEN_INDEX_BUILD_MAX_QUEUE` (default `0` = unlimited; when exceeded, new builds are skipped).
183
256
  ### LOD JIT lane
184
- `ABGEN_LOD_JIT=1` enables JIT LOD builds on `GET /LOD/{0|1}/...` misses; needs `gltfpack`
257
+ `ABGEN_LOD_JIT=1` enables JIT LOD builds on `GET /LOD/1/...` misses (level 1 only, the production
258
+ shape: level 0 is the client-side ISS assembly, so `LOD/0/...` answers `lod-level-unsupported` and
259
+ `abgen-lod generate --level 0,1` is the offline opt-in); needs `gltfpack`
185
260
  (`ABGEN_GLTFPACK` or `$PATH`), fails closed without it. Knobs: `ABGEN_LOD_MANIFEST_BUILDER` (unset
186
261
  limits JIT to scenes with a published ISS descriptor), `ABGEN_LOD_CACHE_DIR` (default:
187
262
  `ABGEN_CACHE_DIR`), `ABGEN_LOD_JIT_TIMEOUT_S` / `ABGEN_LOD_JIT_FAIL_TTL_S` (defaults `600` / `3600`),
188
263
  `ABGEN_LOD_BUILD_CONCURRENCY` (default `1`). Builds stage in a per-build workdir; only gate-passed
189
- output is promoted into the serving root, so rejected bundles are never servable.
264
+ output is promoted into the serving root, so rejected bundles are never servable. A passed build is
265
+ written back to the space with the production key set: `LOD/1/{sid}_1_{platform}`,
266
+ `lods-unity/manifests/{sid}_InitialSceneState.json` and the gltfpack-layout
267
+ `lods-unity/lods/{sid}_1.glb`.
190
268
  ### Conversion / parity knobs
191
269
  - `ABGEN_SHADER_BUNDLE` - path to `scene_ignore_windows` (default `crate/shader/scene_ignore_windows`; siblings like `scene_ignore_mac` resolve from the same dir)
192
270
  - `ABGEN_CONTENT_ROOT` - local sharded content store root (default `./content`)
package/abgen.exe CHANGED
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dcl/abgen-win32-x64",
3
- "version": "0.17.13",
3
+ "version": "0.19.0",
4
4
  "description": "abgen prebuilt binary for win32 x64 (installed by @dcl/abgen)",
5
5
  "license": "AGPL-3.0-or-later",
6
6
  "repository": {