@needle-tools/gltf-build-pipeline 3.0.0-beta → 3.0.0-beta.1
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/CHANGELOG.md +6 -0
- package/dist/cli/index.js +7 -3
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,12 @@ All notable changes to this package will be documented in this file.
|
|
|
4
4
|
The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
|
|
5
5
|
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
|
|
6
6
|
|
|
7
|
+
## [3.0.0-beta.1] - 2026-06-10
|
|
8
|
+
|
|
9
|
+
### Fixed
|
|
10
|
+
- VRM thumbnail (and other textures referenced only through an opaque extension) no longer dangle to the wrong image after prune/dedup re-indexing. When an image was deduped, an extension-carried `KHR_texture_basisu.source` was copied verbatim and left stale — the thumbnail's source could point past the end of the image array and crash three.js on load (`Cannot read properties of undefined (reading 'uri')`), while other affected textures silently resolved to a neighbouring image. Re-running the pipeline on an already-compressed VRM is now covered by tests.
|
|
11
|
+
- Audio URIs now use forward slashes on every platform. On Windows the rewritten clip path was built with `path.join`, producing backslashes that loaders cannot resolve (only affected audio assets in a subfolder).
|
|
12
|
+
|
|
7
13
|
## [3.0.0-alpha] - 2026-05-26
|
|
8
14
|
|
|
9
15
|
### Breaking
|
package/dist/cli/index.js
CHANGED
|
@@ -689,7 +689,11 @@ var GenericWriter = class {
|
|
|
689
689
|
}
|
|
690
690
|
this.debug && console.log("Could not find texture, creating a new one: " + this._debugName);
|
|
691
691
|
let extensions = this.inputDefinition.extensions ? { ...this.inputDefinition.extensions } : void 0;
|
|
692
|
-
extensions && (delete extensions[NEEDLE_progressive_texture_settings.EXTENSION_NAME], extensions.EXT_texture_exr && this.inputObject.getMimeType() !== "image/exr" && delete extensions.EXT_texture_exr, Object.keys(extensions).length === 0 && (extensions = void 0))
|
|
692
|
+
if (extensions && (delete extensions[NEEDLE_progressive_texture_settings.EXTENSION_NAME], extensions.EXT_texture_exr && this.inputObject.getMimeType() !== "image/exr" && delete extensions.EXT_texture_exr, Object.keys(extensions).length === 0 && (extensions = void 0)), extensions)
|
|
693
|
+
for (let key of Object.keys(extensions)) {
|
|
694
|
+
let extDef = extensions[key];
|
|
695
|
+
extDef?.source !== void 0 && (extensions[key] = { ...extDef, source: imgIndex });
|
|
696
|
+
}
|
|
693
697
|
let textureDef = {
|
|
694
698
|
source: extensions && Object.keys(extensions).some((key) => extensions[key]?.source !== void 0) ? void 0 : imgIndex,
|
|
695
699
|
sampler: this.findOrCreateSampler(context.jsonDoc.json),
|
|
@@ -1190,7 +1194,7 @@ function registerExtensions(node) {
|
|
|
1190
1194
|
import { createTransform } from "@gltf-transform/functions";
|
|
1191
1195
|
|
|
1192
1196
|
// src/utils/version.gen.ts
|
|
1193
|
-
var version = "3.0.0-beta";
|
|
1197
|
+
var version = "3.0.0-beta.1";
|
|
1194
1198
|
|
|
1195
1199
|
// src/utils/version.ts
|
|
1196
1200
|
function getVersion(_marklocal = !0) {
|
|
@@ -3600,7 +3604,7 @@ function needle_audio_transform(options) {
|
|
|
3600
3604
|
}
|
|
3601
3605
|
function computeOpusOggUri(sourceUri) {
|
|
3602
3606
|
let dir = dirname6(sourceUri), ext = extname(sourceUri), newName = `${basename3(sourceUri, ext)}.opus.ogg`;
|
|
3603
|
-
return dir === "." || dir === "" ? newName :
|
|
3607
|
+
return (dir === "." || dir === "" ? newName : `${dir}/${newName}`).replaceAll("\\", "/");
|
|
3604
3608
|
}
|
|
3605
3609
|
|
|
3606
3610
|
// src/scripts/pack-gltf.ts
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@needle-tools/gltf-build-pipeline",
|
|
3
|
-
"version": "3.0.0-beta",
|
|
3
|
+
"version": "3.0.0-beta.1",
|
|
4
4
|
"description": "Pipeline and tools for optimizing gltf files using gltf-transform and compression settings within glTF extensions",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|