@carbonenginejs/runtime-resource 0.1.0 → 0.8.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/FORMAT-PROVENANCE.md +155 -135
- package/LICENSE +21 -21
- package/NOTICE +29 -29
- package/README.md +548 -241
- package/dist/CjsMotherLode.js +1271 -56
- package/dist/CjsMotherLode.js.map +1 -1
- package/dist/CjsResMan.js +3005 -740
- package/dist/CjsResMan.js.map +1 -1
- package/dist/CjsResManQueue.js +214 -214
- package/dist/CjsResource.js +566 -366
- package/dist/CjsResource.js.map +1 -1
- package/dist/CjsResourceSource.js +59 -59
- package/dist/_virtual/_rollupPluginBabelHelpers.js +153 -153
- package/dist/format/CjsBlueReader.js +269 -0
- package/dist/format/CjsBlueReader.js.map +1 -0
- package/dist/format/CjsFormat.js +192 -178
- package/dist/format/CjsFormat.js.map +1 -1
- package/dist/format/CjsReader.js +18 -0
- package/dist/format/CjsReader.js.map +1 -0
- package/dist/format/CjsResourceProbe.js +277 -269
- package/dist/format/CjsResourceProbe.js.map +1 -1
- package/dist/format/payloadContract.js +173 -173
- package/dist/formats/black/CjsBlackFormat.js +278 -272
- package/dist/formats/black/CjsBlackFormat.js.map +1 -1
- package/dist/formats/black/core/CjsBlackBinaryReader.js +153 -153
- package/dist/formats/black/core/CjsBlackPropertyReaders.js +382 -382
- package/dist/formats/black/core/CjsBlackReader.js +639 -760
- package/dist/formats/black/core/CjsBlackReader.js.map +1 -1
- package/dist/formats/black/core/CjsBlackSchemaRegistry.js +433 -433
- package/dist/formats/black/core/black-schema-v1-2026-07-11.json.js +4 -4
- package/dist/formats/black/core/blackConstants.js +7 -7
- package/dist/formats/black/core/blackDefinitions.js +10 -10
- package/dist/formats/black/core/blackEnums.js +6 -6
- package/dist/formats/black/core/blackSchema.js +3 -3
- package/dist/formats/black/core/blackVersion.js +22 -22
- package/dist/formats/black/core/helpers.js +182 -182
- package/dist/formats/black/core/schema.js +4 -4
- package/dist/formats/black/index.js +2 -2
- package/dist/formats/bnk/CjsBnkFormat.js +238 -245
- package/dist/formats/bnk/CjsBnkFormat.js.map +1 -1
- package/dist/formats/bnk/core/graph.js +140 -0
- package/dist/formats/bnk/core/graph.js.map +1 -0
- package/dist/formats/bnk/core/helpers.js +409 -354
- package/dist/formats/bnk/core/helpers.js.map +1 -1
- package/dist/formats/bnk/core/musicNodes.js +521 -0
- package/dist/formats/bnk/core/musicNodes.js.map +1 -0
- package/dist/formats/bnk/core/soundbanksInfo.js +246 -246
- package/dist/formats/bnk/index.js +2 -3
- package/dist/formats/bnk/index.js.map +1 -1
- package/dist/formats/cmf/CjsCmfFormat.js +497 -491
- package/dist/formats/cmf/CjsCmfFormat.js.map +1 -1
- package/dist/formats/cmf/core/binary.js +118 -118
- package/dist/formats/cmf/core/buffers.js +233 -233
- package/dist/formats/cmf/core/constants.js +47 -47
- package/dist/formats/cmf/core/gr2Anim.js +453 -453
- package/dist/formats/cmf/core/helpers.js +287 -287
- package/dist/formats/cmf/core/pack.js +276 -276
- package/dist/formats/cmf/core/schema.js +364 -364
- package/dist/formats/cmf/core/shared.js +268 -268
- package/dist/formats/cmf/core/writer.js +517 -517
- package/dist/formats/cmf/index.js +2 -2
- package/dist/formats/dds/CjsDdsFormat.js +193 -187
- package/dist/formats/dds/CjsDdsFormat.js.map +1 -1
- package/dist/formats/dds/core/bc6h.js +288 -0
- package/dist/formats/dds/core/bc6h.js.map +1 -0
- package/dist/formats/dds/core/bc7.js +251 -0
- package/dist/formats/dds/core/bc7.js.map +1 -0
- package/dist/formats/dds/core/helpers.js +815 -812
- package/dist/formats/dds/core/helpers.js.map +1 -1
- package/dist/formats/dds/index.js +2 -2
- package/dist/formats/fbx/CjsFbxFormat.js +266 -260
- package/dist/formats/fbx/CjsFbxFormat.js.map +1 -1
- package/dist/formats/fbx/core/helpers.js +3901 -3901
- package/dist/formats/fbx/index.js +2 -2
- package/dist/formats/flac/CjsFlacFormat.js +87 -81
- package/dist/formats/flac/CjsFlacFormat.js.map +1 -1
- package/dist/formats/flac/core/helpers.js +295 -295
- package/dist/formats/flac/index.js +2 -2
- package/dist/formats/gif/CjsGifFormat.js +87 -81
- package/dist/formats/gif/CjsGifFormat.js.map +1 -1
- package/dist/formats/gif/core/helpers.js +360 -360
- package/dist/formats/gif/index.js +2 -2
- package/dist/formats/gltf/CjsGltfFormat.js +290 -284
- package/dist/formats/gltf/CjsGltfFormat.js.map +1 -1
- package/dist/formats/gltf/core/helpers.js +292 -292
- package/dist/formats/gltf/core/json.js +79 -79
- package/dist/formats/gltf/core/parser.js +666 -666
- package/dist/formats/gltf/core/targets.js +163 -163
- package/dist/formats/gltf/index.js +2 -2
- package/dist/formats/index.js +23 -23
- package/dist/formats/jpeg/CjsJpegFormat.js +206 -200
- package/dist/formats/jpeg/CjsJpegFormat.js.map +1 -1
- package/dist/formats/jpeg/core/helpers.js +350 -350
- package/dist/formats/jpeg/core/jpeg.js +377 -377
- package/dist/formats/jpeg/index.js +2 -2
- package/dist/formats/mp3/CjsMp3Format.js +192 -186
- package/dist/formats/mp3/CjsMp3Format.js.map +1 -1
- package/dist/formats/mp3/core/helpers.js +338 -338
- package/dist/formats/mp3/index.js +2 -2
- package/dist/formats/mp4/CjsMp4Format.js +191 -185
- package/dist/formats/mp4/CjsMp4Format.js.map +1 -1
- package/dist/formats/mp4/core/helpers.js +449 -449
- package/dist/formats/mp4/index.js +2 -2
- package/dist/formats/obj/CjsObjFormat.js +253 -247
- package/dist/formats/obj/CjsObjFormat.js.map +1 -1
- package/dist/formats/obj/core/helpers.js +573 -573
- package/dist/formats/obj/core/json.js +64 -64
- package/dist/formats/obj/core/parser.js +321 -321
- package/dist/formats/obj/index.js +2 -2
- package/dist/formats/ogg/CjsOggFormat.js +88 -82
- package/dist/formats/ogg/CjsOggFormat.js.map +1 -1
- package/dist/formats/ogg/core/helpers.js +387 -387
- package/dist/formats/ogg/core/imdct.js +178 -178
- package/dist/formats/ogg/core/vorbis.js +999 -999
- package/dist/formats/ogg/index.js +2 -2
- package/dist/formats/png/CjsPngFormat.js +195 -189
- package/dist/formats/png/CjsPngFormat.js.map +1 -1
- package/dist/formats/png/core/helpers.js +583 -583
- package/dist/formats/png/index.js +2 -2
- package/dist/formats/red/CjsRedFormat.js +261 -247
- package/dist/formats/red/CjsRedFormat.js.map +1 -1
- package/dist/formats/red/core/CjsRedReader.js +194 -201
- package/dist/formats/red/core/CjsRedReader.js.map +1 -1
- package/dist/formats/red/core/blackDefinitions.js +3 -3
- package/dist/formats/red/core/helpers.js +139 -136
- package/dist/formats/red/core/helpers.js.map +1 -1
- package/dist/formats/red/core/redGraph.js +68 -68
- package/dist/formats/red/core/schema.js +4 -4
- package/dist/formats/red/index.js +2 -2
- package/dist/formats/stl/CjsStlFormat.js +365 -304
- package/dist/formats/stl/CjsStlFormat.js.map +1 -1
- package/dist/formats/stl/core/helpers.js +261 -257
- package/dist/formats/stl/core/helpers.js.map +1 -1
- package/dist/formats/stl/core/json.js +51 -51
- package/dist/formats/stl/core/stl.js +629 -544
- package/dist/formats/stl/core/stl.js.map +1 -1
- package/dist/formats/stl/core/targets.js +163 -163
- package/dist/formats/stl/index.js +2 -2
- package/dist/formats/tga/CjsTgaFormat.js +192 -186
- package/dist/formats/tga/CjsTgaFormat.js.map +1 -1
- package/dist/formats/tga/core/helpers.js +446 -446
- package/dist/formats/tga/index.js +2 -2
- package/dist/formats/wav/CjsWavFormat.js +192 -186
- package/dist/formats/wav/CjsWavFormat.js.map +1 -1
- package/dist/formats/wav/core/helpers.js +328 -328
- package/dist/formats/wav/index.js +2 -2
- package/dist/formats/webm/CjsWebmFormat.js +191 -185
- package/dist/formats/webm/CjsWebmFormat.js.map +1 -1
- package/dist/formats/webm/core/helpers.js +537 -537
- package/dist/formats/webm/index.js +2 -2
- package/dist/formats/webp/CjsWebpFormat.js +86 -80
- package/dist/formats/webp/CjsWebpFormat.js.map +1 -1
- package/dist/formats/webp/core/helpers.js +214 -214
- package/dist/formats/webp/index.js +2 -2
- package/dist/formats/wem/CjsWemFormat.js +241 -197
- package/dist/formats/wem/CjsWemFormat.js.map +1 -1
- package/dist/formats/wem/core/bitStream.js +259 -259
- package/dist/formats/wem/core/codebookLibrary.js +164 -164
- package/dist/formats/wem/core/helpers.js +417 -336
- package/dist/formats/wem/core/helpers.js.map +1 -1
- package/dist/formats/wem/core/packedCodebooksAotuv603.js +30 -30
- package/dist/formats/wem/core/ptadpcm.js +77 -0
- package/dist/formats/wem/core/ptadpcm.js.map +1 -0
- package/dist/formats/wem/core/resolve.js +121 -0
- package/dist/formats/wem/core/resolve.js.map +1 -0
- package/dist/formats/wem/core/wemToOgg.js +485 -485
- package/dist/formats/wem/index.js +2 -2
- package/dist/formats/yaml/CjsYamlFormat.js +83 -77
- package/dist/formats/yaml/CjsYamlFormat.js.map +1 -1
- package/dist/formats/yaml/core/CjsYamlReader.js +305 -304
- package/dist/formats/yaml/core/CjsYamlReader.js.map +1 -1
- package/dist/formats/yaml/core/helpers.js +160 -160
- package/dist/formats/yaml/index.js +2 -2
- package/dist/index.js +48 -52
- package/dist/index.js.map +1 -1
- package/dist/resourcePath.js +18 -18
- package/dist/resourceStates.js +9 -9
- package/dist/{generated/resources → resources}/AudioGeometryResData.js +47 -47
- package/dist/resources/AudioGeometryResData.js.map +1 -0
- package/dist/{generated/resources → resources}/GStateBindingCallbackData.js +31 -31
- package/dist/resources/GStateBindingCallbackData.js.map +1 -0
- package/dist/{generated/resources → resources}/MeshDecalData.js +37 -37
- package/dist/resources/MeshDecalData.js.map +1 -0
- package/dist/{generated/resources → resources}/MeshDecalLodData.js +34 -34
- package/dist/resources/MeshDecalLodData.js.map +1 -0
- package/dist/resources/Tr2EffectRes.js +71 -71
- package/dist/resources/Tr2GrannyIntersectionResult.js +60 -0
- package/dist/resources/Tr2GrannyIntersectionResult.js.map +1 -0
- package/dist/resources/Tr2GrannyStateRes.js +44 -44
- package/dist/resources/Tr2ImageRes.js +114 -114
- package/dist/resources/Tr2LightProfileRes.js +40 -40
- package/dist/{generated/resources → resources}/Tr2MaterialArea.js +34 -34
- package/dist/resources/Tr2MaterialArea.js.map +1 -0
- package/dist/{generated/resources → resources}/Tr2MaterialMesh.js +31 -31
- package/dist/resources/Tr2MaterialMesh.js.map +1 -0
- package/dist/{generated/resources → resources}/Tr2MaterialRes.js +34 -34
- package/dist/resources/Tr2MaterialRes.js.map +1 -0
- package/dist/{generated/resources → resources}/Tr2ShaderPermutation.js +43 -43
- package/dist/resources/Tr2ShaderPermutation.js.map +1 -0
- package/dist/{generated/resources → resources}/Tr2TextureLodManager.js +100 -60
- package/dist/resources/Tr2TextureLodManager.js.map +1 -0
- package/dist/{generated/resources → resources}/Tr2TextureLodUpdateRequest.js +37 -37
- package/dist/resources/Tr2TextureLodUpdateRequest.js.map +1 -0
- package/dist/{generated/resources → resources}/Tr2TexturePackChannel.js +37 -37
- package/dist/resources/Tr2TexturePackChannel.js.map +1 -0
- package/dist/resources/Tr2TexturePipeline.js +68 -0
- package/dist/resources/Tr2TexturePipeline.js.map +1 -0
- package/dist/{generated/resources → resources}/Tr2TexturePipelineParams.js +34 -34
- package/dist/resources/Tr2TexturePipelineParams.js.map +1 -0
- package/dist/{generated/resources → resources}/Tr2TexturePipelineStepCompress.js +40 -40
- package/dist/resources/Tr2TexturePipelineStepCompress.js.map +1 -0
- package/dist/{generated/resources → resources}/Tr2TexturePipelineStepLimitSize.js +34 -34
- package/dist/resources/Tr2TexturePipelineStepLimitSize.js.map +1 -0
- package/dist/{generated/resources → resources}/Tr2TexturePipelineStepLoad.js +31 -31
- package/dist/resources/Tr2TexturePipelineStepLoad.js.map +1 -0
- package/dist/{generated/resources → resources}/Tr2TexturePipelineStepPack.js +43 -43
- package/dist/resources/Tr2TexturePipelineStepPack.js.map +1 -0
- package/dist/resources/TriGeometryRes.js +239 -216
- package/dist/resources/TriGeometryRes.js.map +1 -1
- package/dist/{generated/resources → resources}/TriGeometryResAreaData.js +59 -59
- package/dist/resources/TriGeometryResAreaData.js.map +1 -0
- package/dist/{generated/resources → resources}/TriGeometryResJointData.js +38 -38
- package/dist/resources/TriGeometryResJointData.js.map +1 -0
- package/dist/{generated/resources → resources}/TriGeometryResLodData.js +88 -88
- package/dist/resources/TriGeometryResLodData.js.map +1 -0
- package/dist/{generated/resources → resources}/TriGeometryResMeshData.js +63 -63
- package/dist/resources/TriGeometryResMeshData.js.map +1 -0
- package/dist/{generated/resources → resources}/TriGeometryResSkeletonData.js +34 -34
- package/dist/resources/TriGeometryResSkeletonData.js.map +1 -0
- package/dist/resources/TriGrannyRes.js +43 -43
- package/dist/{generated/resources → resources}/TriJointBinding.js +38 -38
- package/dist/resources/TriJointBinding.js.map +1 -0
- package/dist/{generated/resources → resources}/TriMorphTargetGeometryConstants.js +46 -46
- package/dist/resources/TriMorphTargetGeometryConstants.js.map +1 -0
- package/dist/{generated/resources → resources}/TriRtGeometryConstants.js +88 -88
- package/dist/resources/TriRtGeometryConstants.js.map +1 -0
- package/dist/resources/TriTextureRes.js +304 -304
- package/dist/{generated/resources → resources}/enums.js +18 -18
- package/dist/resources/enums.js.map +1 -0
- package/dist/resources/resourceBoundary.js +47 -47
- package/dist/resources/texturePipelineBehavior.js +320 -0
- package/dist/resources/texturePipelineBehavior.js.map +1 -0
- package/dist/texture/CjsTextureArrayRes.js +406 -406
- package/dist/texture/CjsTextureParameterProxy.js +133 -133
- package/format-notices/black/LICENSE +21 -21
- package/format-notices/black/NOTICE +47 -47
- package/format-notices/bnk/LICENSE +21 -21
- package/format-notices/bnk/NOTICE +20 -17
- package/format-notices/cmf/LICENSE +21 -21
- package/format-notices/cmf/NOTICE +36 -36
- package/format-notices/dds/LICENSE +21 -21
- package/format-notices/dds/NOTICE +14 -14
- package/format-notices/fbx/LICENSE +21 -21
- package/format-notices/fbx/NOTICE +14 -14
- package/format-notices/flac/LICENSE +21 -21
- package/format-notices/flac/NOTICE +14 -14
- package/format-notices/gif/LICENSE +21 -21
- package/format-notices/gif/NOTICE +14 -14
- package/format-notices/gltf/LICENSE +21 -21
- package/format-notices/gltf/NOTICE +27 -27
- package/format-notices/jpeg/LICENSE +21 -21
- package/format-notices/jpeg/NOTICE +14 -14
- package/format-notices/mp3/LICENSE +21 -21
- package/format-notices/mp3/NOTICE +14 -14
- package/format-notices/mp4/LICENSE +21 -21
- package/format-notices/mp4/NOTICE +14 -14
- package/format-notices/obj/LICENSE +21 -21
- package/format-notices/obj/NOTICE +26 -26
- package/format-notices/ogg/LICENSE +21 -21
- package/format-notices/ogg/NOTICE +28 -28
- package/format-notices/png/LICENSE +21 -21
- package/format-notices/png/NOTICE +14 -14
- package/format-notices/red/LICENSE +21 -21
- package/format-notices/red/NOTICE +31 -31
- package/format-notices/stl/LICENSE +21 -21
- package/format-notices/stl/NOTICE +21 -21
- package/format-notices/tga/LICENSE +21 -21
- package/format-notices/tga/NOTICE +14 -14
- package/format-notices/wav/LICENSE +21 -21
- package/format-notices/wav/NOTICE +14 -14
- package/format-notices/webm/LICENSE +21 -21
- package/format-notices/webm/NOTICE +14 -14
- package/format-notices/webp/LICENSE +21 -21
- package/format-notices/webp/NOTICE +14 -14
- package/format-notices/wem/LICENSE +57 -57
- package/format-notices/wem/NOTICE +33 -33
- package/format-notices/yaml/LICENSE +21 -21
- package/format-notices/yaml/NOTICE +44 -44
- package/package.json +51 -51
- package/resource-lifecycle.md +679 -487
- package/dist/generated/resources/AudioGeometryResData.js.map +0 -1
- package/dist/generated/resources/CmfVertexReader.js +0 -46
- package/dist/generated/resources/CmfVertexReader.js.map +0 -1
- package/dist/generated/resources/GStateBindingCallbackData.js.map +0 -1
- package/dist/generated/resources/MeshDecalData.js.map +0 -1
- package/dist/generated/resources/MeshDecalLodData.js.map +0 -1
- package/dist/generated/resources/Tr2AsyncSave.js +0 -46
- package/dist/generated/resources/Tr2AsyncSave.js.map +0 -1
- package/dist/generated/resources/Tr2CmfContents.js +0 -37
- package/dist/generated/resources/Tr2CmfContents.js.map +0 -1
- package/dist/generated/resources/Tr2GrannyIntersectionResult.js +0 -58
- package/dist/generated/resources/Tr2GrannyIntersectionResult.js.map +0 -1
- package/dist/generated/resources/Tr2LoadPrepareFence.js +0 -37
- package/dist/generated/resources/Tr2LoadPrepareFence.js.map +0 -1
- package/dist/generated/resources/Tr2MaterialArea.js.map +0 -1
- package/dist/generated/resources/Tr2MaterialMesh.js.map +0 -1
- package/dist/generated/resources/Tr2MaterialRes.js.map +0 -1
- package/dist/generated/resources/Tr2ShaderPermutation.js.map +0 -1
- package/dist/generated/resources/Tr2TextureLodManager.js.map +0 -1
- package/dist/generated/resources/Tr2TextureLodUpdateRequest.js.map +0 -1
- package/dist/generated/resources/Tr2TexturePackChannel.js.map +0 -1
- package/dist/generated/resources/Tr2TexturePipeline.js +0 -44
- package/dist/generated/resources/Tr2TexturePipeline.js.map +0 -1
- package/dist/generated/resources/Tr2TexturePipelineParams.js.map +0 -1
- package/dist/generated/resources/Tr2TexturePipelineStepCompress.js.map +0 -1
- package/dist/generated/resources/Tr2TexturePipelineStepLimitSize.js.map +0 -1
- package/dist/generated/resources/Tr2TexturePipelineStepLoad.js.map +0 -1
- package/dist/generated/resources/Tr2TexturePipelineStepPack.js.map +0 -1
- package/dist/generated/resources/TriGeometryResAreaData.js.map +0 -1
- package/dist/generated/resources/TriGeometryResJointData.js.map +0 -1
- package/dist/generated/resources/TriGeometryResLodData.js.map +0 -1
- package/dist/generated/resources/TriGeometryResMeshData.js.map +0 -1
- package/dist/generated/resources/TriGeometryResSkeletonData.js.map +0 -1
- package/dist/generated/resources/TriJointBinding.js.map +0 -1
- package/dist/generated/resources/TriMorphTargetGeometryConstants.js.map +0 -1
- package/dist/generated/resources/TriRtGeometryConstants.js.map +0 -1
- package/dist/generated/resources/enums.js.map +0 -1
- package/dist/generated/resources/index.js +0 -32
- package/dist/generated/resources/index.js.map +0 -1
|
@@ -1,245 +1,238 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { DEFAULT_VALUES, normalizeValues, readWithValues, inspectWithValues, isSupportedWithValues, toJsonValue, toBytes, extractMedia, isBNK,
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
*
|
|
10
|
-
*
|
|
11
|
-
* the
|
|
12
|
-
*
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
*
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
*
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
*
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
*
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
*
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
*
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
*
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
*
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
*
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
*
|
|
190
|
-
*
|
|
191
|
-
*
|
|
192
|
-
*
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
*
|
|
200
|
-
*
|
|
201
|
-
*
|
|
202
|
-
*
|
|
203
|
-
*
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
*
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
static
|
|
233
|
-
static
|
|
234
|
-
static
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
static inputTypes = Object.freeze(["bnk"]);
|
|
240
|
-
static outputTypes = Object.freeze([OUTPUT_RAW, OUTPUT_MEDIA]);
|
|
241
|
-
static debugOutputTypes = Object.freeze([OUTPUT_BNK_JSON, OUTPUT_RAW]);
|
|
242
|
-
}
|
|
243
|
-
|
|
244
|
-
export { CjsBnkFormat };
|
|
245
|
-
//# sourceMappingURL=CjsBnkFormat.js.map
|
|
1
|
+
import { wwiseIdFromName, joinSoundbanksInfo, buildSoundbanksCatalog, parseSoundbanksInfo, isSoundbanksInfo } from './core/soundbanksInfo.js';
|
|
2
|
+
import { DEFAULT_VALUES, normalizeValues, readWithValues, inspectWithValues, isSupportedWithValues, toJsonValue, toBytes, extractMedia, isBNK, OUTPUT_MEDIA, OUTPUT_BNK_JSON, OUTPUT_JSON, OUTPUT_RAW, HIRC_TYPE_NAMES } from './core/helpers.js';
|
|
3
|
+
import { eventMediaFromBanks } from './core/graph.js';
|
|
4
|
+
import { parseMusicSwitch, parseMusicPlaylist, parseMusicTrack, parseMusicSegment, musicNodesFromBanks } from './core/musicNodes.js';
|
|
5
|
+
|
|
6
|
+
const FORMAT_NAME = "CjsBnkFormat";
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* Reader for Audiokinetic Wwise soundbank (.bnk) containers.
|
|
10
|
+
*
|
|
11
|
+
* Inspection decodes the bank header, embedded media index, object hierarchy
|
|
12
|
+
* listing (with version-stable typed fields), and referenced bank names
|
|
13
|
+
* without copying payloads. Read can emit the raw bank, debug JSON, or the
|
|
14
|
+
* embedded media items undecoded. The read path stays a pure container
|
|
15
|
+
* reader; the Wwise-domain toolkit (SoundbanksInfo catalog helpers, id hash,
|
|
16
|
+
* event -> media graph resolution) is grouped under the `wwise` static.
|
|
17
|
+
*/
|
|
18
|
+
class CjsBnkFormat {
|
|
19
|
+
#values = DEFAULT_VALUES;
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* Create a reusable bnk format profile.
|
|
23
|
+
*
|
|
24
|
+
* @param {object} [options] Default read/inspect options.
|
|
25
|
+
*/
|
|
26
|
+
constructor(options = {}) {
|
|
27
|
+
this.SetValues(options);
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Merge options into this profile.
|
|
32
|
+
*
|
|
33
|
+
* @param {object} [options] Values to merge.
|
|
34
|
+
* @returns {CjsBnkFormat} This format profile.
|
|
35
|
+
*/
|
|
36
|
+
SetValues(options = {}) {
|
|
37
|
+
this.#values = normalizeValues(this.#values, options, FORMAT_NAME);
|
|
38
|
+
return this;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* Get normalized profile values with optional per-call overrides.
|
|
43
|
+
*
|
|
44
|
+
* @param {object} [options] Per-call values.
|
|
45
|
+
* @returns {object} Normalized read values.
|
|
46
|
+
*/
|
|
47
|
+
GetValues(options = {}) {
|
|
48
|
+
return normalizeValues(this.#values, options, FORMAT_NAME);
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* Read soundbank bytes with this profile.
|
|
53
|
+
*
|
|
54
|
+
* @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.
|
|
55
|
+
* @param {object} [options] Per-call values.
|
|
56
|
+
* @returns {object} GPU-free raw/debug/media payload for the selected emit target.
|
|
57
|
+
*/
|
|
58
|
+
Read(input, options = {}) {
|
|
59
|
+
return readWithValues(input, this.GetValues(options));
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
/**
|
|
63
|
+
* Read soundbank bytes asynchronously with this profile.
|
|
64
|
+
*
|
|
65
|
+
* @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.
|
|
66
|
+
* @param {object} [options] Per-call values.
|
|
67
|
+
* @returns {Promise<object>} GPU-free raw/debug/media payload for the selected emit target.
|
|
68
|
+
*/
|
|
69
|
+
async ReadAsync(input, options = {}) {
|
|
70
|
+
return this.Read(input, options);
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
/**
|
|
74
|
+
* Inspect soundbank bytes without copying media payloads.
|
|
75
|
+
*
|
|
76
|
+
* @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.
|
|
77
|
+
* @param {object} [options] Per-call values.
|
|
78
|
+
* @returns {object} Soundbank metadata.
|
|
79
|
+
*/
|
|
80
|
+
Inspect(input, options = {}) {
|
|
81
|
+
return inspectWithValues(input, this.GetValues(options));
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
/**
|
|
85
|
+
* Report whether soundbank input and requested output variants are supported.
|
|
86
|
+
*
|
|
87
|
+
* @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.
|
|
88
|
+
* @param {object} [options] Per-call values.
|
|
89
|
+
* @returns {object} Support/probe report.
|
|
90
|
+
*/
|
|
91
|
+
IsSupported(input, options = {}) {
|
|
92
|
+
return isSupportedWithValues(input, this.GetValues(options));
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
/**
|
|
96
|
+
* Convert format output into JSON-compatible debug data.
|
|
97
|
+
*
|
|
98
|
+
* @param {any} value Format output.
|
|
99
|
+
* @returns {any} JSON-compatible value.
|
|
100
|
+
*/
|
|
101
|
+
ToJSON(value) {
|
|
102
|
+
return toJsonValue(value);
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
/**
|
|
106
|
+
* One-shot soundbank read.
|
|
107
|
+
*
|
|
108
|
+
* @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.
|
|
109
|
+
* @param {object} [options] Read options.
|
|
110
|
+
* @returns {object} GPU-free raw/debug/media payload for the selected emit target.
|
|
111
|
+
*/
|
|
112
|
+
static read(input, options = {}) {
|
|
113
|
+
return readWithValues(input, normalizeValues(DEFAULT_VALUES, options, FORMAT_NAME));
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
/**
|
|
117
|
+
* One-shot asynchronous soundbank read.
|
|
118
|
+
*
|
|
119
|
+
* @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.
|
|
120
|
+
* @param {object} [options] Read options.
|
|
121
|
+
* @returns {Promise<object>} GPU-free raw/debug/media payload for the selected emit target.
|
|
122
|
+
*/
|
|
123
|
+
static async readAsync(input, options = {}) {
|
|
124
|
+
return CjsBnkFormat.read(input, options);
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
/**
|
|
128
|
+
* One-shot soundbank inspection.
|
|
129
|
+
*
|
|
130
|
+
* @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.
|
|
131
|
+
* @param {object} [options] Inspect options.
|
|
132
|
+
* @returns {object} Soundbank metadata.
|
|
133
|
+
*/
|
|
134
|
+
static inspect(input, options = {}) {
|
|
135
|
+
return inspectWithValues(input, normalizeValues(DEFAULT_VALUES, options, FORMAT_NAME));
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
/**
|
|
139
|
+
* One-shot soundbank support probe.
|
|
140
|
+
*
|
|
141
|
+
* @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.
|
|
142
|
+
* @param {object} [options] Probe options.
|
|
143
|
+
* @returns {object} Support/probe report.
|
|
144
|
+
*/
|
|
145
|
+
static isSupported(input, options = {}) {
|
|
146
|
+
return isSupportedWithValues(input, normalizeValues(DEFAULT_VALUES, options, FORMAT_NAME));
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
/**
|
|
150
|
+
* Extract embedded media payloads as views over the soundbank bytes.
|
|
151
|
+
*
|
|
152
|
+
* @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.
|
|
153
|
+
* @param {number} [mediaId] Optional single media id filter.
|
|
154
|
+
* @returns {Array<object>} Extracted media items with undecoded bytes.
|
|
155
|
+
*/
|
|
156
|
+
static extractMedia(input, mediaId) {
|
|
157
|
+
const bytes = toBytes(input);
|
|
158
|
+
const metadata = inspectWithValues(bytes, DEFAULT_VALUES);
|
|
159
|
+
return extractMedia(bytes, metadata, mediaId);
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
/**
|
|
163
|
+
* Convert format output into JSON-compatible debug data.
|
|
164
|
+
*
|
|
165
|
+
* @param {any} value Format output.
|
|
166
|
+
* @returns {any} JSON-compatible value.
|
|
167
|
+
*/
|
|
168
|
+
static toJSON(value) {
|
|
169
|
+
return toJsonValue(value);
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
/**
|
|
173
|
+
* Test whether bytes look like a Wwise soundbank.
|
|
174
|
+
*
|
|
175
|
+
* @param {Uint8Array|ArrayBuffer|DataView} input Candidate soundbank bytes.
|
|
176
|
+
* @returns {boolean} True when the BKHD header chunk is present.
|
|
177
|
+
*/
|
|
178
|
+
static isBNK(input) {
|
|
179
|
+
try {
|
|
180
|
+
return isBNK(toBytes(input));
|
|
181
|
+
} catch {
|
|
182
|
+
return false;
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
/**
|
|
187
|
+
* Wwise-domain toolkit, grouped apart from the container-reading statics -
|
|
188
|
+
* the single home for the SoundbanksInfo catalog helpers
|
|
189
|
+
* (`isSoundbanksInfo`, `parseSoundbanksInfo`, `buildSoundbanksCatalog`,
|
|
190
|
+
* `joinSoundbanksInfo`), the id hash (`wwiseIdFromName`, FNV-1 of the
|
|
191
|
+
* lowercased name), and event-graph resolution.
|
|
192
|
+
*
|
|
193
|
+
* `eventMediaFromBanks(inspections, options)` is graph interpretation over
|
|
194
|
+
* `inspect()` results, not a read path: banks may split events from their
|
|
195
|
+
* target objects (EVE keeps all events in one bank and their sounds in
|
|
196
|
+
* others), so always pass every related bank to one call. Returns
|
|
197
|
+
* `{ eventMedia: Map<eventObjectId, Set<wemId>>, diagnostics }`. See
|
|
198
|
+
* core/graph.js for the walk policy.
|
|
199
|
+
*
|
|
200
|
+
* The interactive-music decoders (`musicNodesFromBanks` and the per-type
|
|
201
|
+
* `parseMusicSegment/Track/Playlist/Switch`) turn the music-hierarchy
|
|
202
|
+
* entries (HIRC 10-13) into typed nodes - children, meter, cue markers,
|
|
203
|
+
* clips, playlist trees, decision trees, and transition rules. See
|
|
204
|
+
* core/musicNodes.js for the anchored, exact-end-validated parse.
|
|
205
|
+
*/
|
|
206
|
+
static wwise = Object.freeze({
|
|
207
|
+
isSoundbanksInfo,
|
|
208
|
+
parseSoundbanksInfo,
|
|
209
|
+
buildSoundbanksCatalog,
|
|
210
|
+
joinSoundbanksInfo,
|
|
211
|
+
wwiseIdFromName,
|
|
212
|
+
eventMediaFromBanks,
|
|
213
|
+
musicNodesFromBanks,
|
|
214
|
+
parseMusicSegment,
|
|
215
|
+
parseMusicTrack,
|
|
216
|
+
parseMusicPlaylist,
|
|
217
|
+
parseMusicSwitch
|
|
218
|
+
});
|
|
219
|
+
|
|
220
|
+
/**
|
|
221
|
+
* Emit targets for this format (canonical frozen enum).
|
|
222
|
+
*/
|
|
223
|
+
static Output = Object.freeze({
|
|
224
|
+
RAW: OUTPUT_RAW,
|
|
225
|
+
JSON: OUTPUT_JSON,
|
|
226
|
+
BNK_JSON: OUTPUT_BNK_JSON,
|
|
227
|
+
MEDIA: OUTPUT_MEDIA
|
|
228
|
+
});
|
|
229
|
+
static HIRC_TYPE_NAMES = HIRC_TYPE_NAMES;
|
|
230
|
+
static type = Object.freeze(["audio"]);
|
|
231
|
+
static mediaTypes = Object.freeze(["audio"]);
|
|
232
|
+
static inputTypes = Object.freeze(["bnk"]);
|
|
233
|
+
static outputTypes = Object.freeze([OUTPUT_RAW, OUTPUT_MEDIA]);
|
|
234
|
+
static debugOutputTypes = Object.freeze([OUTPUT_BNK_JSON, OUTPUT_RAW]);
|
|
235
|
+
}
|
|
236
|
+
|
|
237
|
+
export { CjsBnkFormat };
|
|
238
|
+
//# sourceMappingURL=CjsBnkFormat.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CjsBnkFormat.js","sources":["../../../../src/formats/bnk/CjsBnkFormat.js"],"sourcesContent":["import {\n buildSoundbanksCatalog,\n isSoundbanksInfo,\n joinSoundbanksInfo,\n parseSoundbanksInfo,\n wwiseIdFromName\n} from \"./core/soundbanksInfo.js\";\nimport {\n DEFAULT_VALUES,\n HIRC_TYPE_NAMES,\n OUTPUT_BNK_JSON,\n OUTPUT_JSON,\n OUTPUT_MEDIA,\n OUTPUT_RAW,\n extractMedia,\n inspectWithValues,\n isBNK,\n isSupportedWithValues,\n normalizeValues,\n readWithValues,\n toBytes,\n toJsonValue\n} from \"./core/helpers.js\";\n\nconst FORMAT_NAME = \"CjsBnkFormat\";\n\n/**\n * Reader for Audiokinetic Wwise soundbank (.bnk) containers.\n *\n * Inspection decodes the bank header, embedded media index, object hierarchy\n * listing, and referenced bank names without copying payloads. Read can emit\n * the raw bank, debug JSON, or the embedded media items undecoded; Wwise\n * event/graph semantics are deliberately out of scope for this reader.\n */\nexport class CjsBnkFormat\n{\n #values = DEFAULT_VALUES;\n\n /**\n * Create a reusable bnk format profile.\n *\n * @param {object} [options] Default read/inspect options.\n */\n constructor(options = {})\n {\n this.SetValues(options);\n }\n\n /**\n * Merge options into this profile.\n *\n * @param {object} [options] Values to merge.\n * @returns {CjsBnkFormat} This format profile.\n */\n SetValues(options = {})\n {\n this.#values = normalizeValues(this.#values, options, FORMAT_NAME);\n return this;\n }\n\n /**\n * Get normalized profile values with optional per-call overrides.\n *\n * @param {object} [options] Per-call values.\n * @returns {object} Normalized read values.\n */\n GetValues(options = {})\n {\n return normalizeValues(this.#values, options, FORMAT_NAME);\n }\n\n /**\n * Read soundbank bytes with this profile.\n *\n * @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.\n * @param {object} [options] Per-call values.\n * @returns {object} GPU-free raw/debug/media payload for the selected emit target.\n */\n Read(input, options = {})\n {\n return readWithValues(input, this.GetValues(options));\n }\n\n /**\n * Read soundbank bytes asynchronously with this profile.\n *\n * @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.\n * @param {object} [options] Per-call values.\n * @returns {Promise<object>} GPU-free raw/debug/media payload for the selected emit target.\n */\n async ReadAsync(input, options = {})\n {\n return this.Read(input, options);\n }\n\n /**\n * Inspect soundbank bytes without copying media payloads.\n *\n * @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.\n * @param {object} [options] Per-call values.\n * @returns {object} Soundbank metadata.\n */\n Inspect(input, options = {})\n {\n return inspectWithValues(input, this.GetValues(options));\n }\n\n /**\n * Report whether soundbank input and requested output variants are supported.\n *\n * @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.\n * @param {object} [options] Per-call values.\n * @returns {object} Support/probe report.\n */\n IsSupported(input, options = {})\n {\n return isSupportedWithValues(input, this.GetValues(options));\n }\n\n /**\n * Convert format output into JSON-compatible debug data.\n *\n * @param {any} value Format output.\n * @returns {any} JSON-compatible value.\n */\n ToJSON(value)\n {\n return toJsonValue(value);\n }\n\n /**\n * One-shot soundbank read.\n *\n * @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.\n * @param {object} [options] Read options.\n * @returns {object} GPU-free raw/debug/media payload for the selected emit target.\n */\n static read(input, options = {})\n {\n return readWithValues(input, normalizeValues(DEFAULT_VALUES, options, FORMAT_NAME));\n }\n\n /**\n * One-shot asynchronous soundbank read.\n *\n * @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.\n * @param {object} [options] Read options.\n * @returns {Promise<object>} GPU-free raw/debug/media payload for the selected emit target.\n */\n static async readAsync(input, options = {})\n {\n return CjsBnkFormat.read(input, options);\n }\n\n /**\n * One-shot soundbank inspection.\n *\n * @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.\n * @param {object} [options] Inspect options.\n * @returns {object} Soundbank metadata.\n */\n static inspect(input, options = {})\n {\n return inspectWithValues(input, normalizeValues(DEFAULT_VALUES, options, FORMAT_NAME));\n }\n\n /**\n * One-shot soundbank support probe.\n *\n * @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.\n * @param {object} [options] Probe options.\n * @returns {object} Support/probe report.\n */\n static isSupported(input, options = {})\n {\n return isSupportedWithValues(input, normalizeValues(DEFAULT_VALUES, options, FORMAT_NAME));\n }\n\n /**\n * Extract embedded media payloads as views over the soundbank bytes.\n *\n * @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.\n * @param {number} [mediaId] Optional single media id filter.\n * @returns {Array<object>} Extracted media items with undecoded bytes.\n */\n static extractMedia(input, mediaId)\n {\n const bytes = toBytes(input);\n const metadata = inspectWithValues(bytes, DEFAULT_VALUES);\n return extractMedia(bytes, metadata, mediaId);\n }\n\n /**\n * Convert format output into JSON-compatible debug data.\n *\n * @param {any} value Format output.\n * @returns {any} JSON-compatible value.\n */\n static toJSON(value)\n {\n return toJsonValue(value);\n }\n\n /**\n * Test whether input looks like a Wwise SoundbanksInfo document.\n *\n * @param {Uint8Array|ArrayBuffer|DataView|string|object} input Candidate document.\n * @returns {boolean} True when a SoundBanksInfo bank list is present.\n */\n static isSoundbanksInfo(input)\n {\n return isSoundbanksInfo(input);\n }\n\n /**\n * Parse a SoundbanksInfo document into a normalized summary.\n *\n * @param {Uint8Array|ArrayBuffer|DataView|string|object} input SoundbanksInfo JSON bytes, text, or object.\n * @returns {object} Normalized document summary with per-bank details.\n */\n static parseSoundbanksInfo(input)\n {\n return parseSoundbanksInfo(input);\n }\n\n /**\n * Build id-keyed lookup tables from a SoundbanksInfo document.\n *\n * @param {Uint8Array|ArrayBuffer|DataView|string|object} input SoundbanksInfo JSON bytes, text, or object.\n * @returns {object} Catalog with banksById, mediaById, eventsById, and eventsByName.\n */\n static buildSoundbanksCatalog(input)\n {\n return buildSoundbanksCatalog(input);\n }\n\n /**\n * Join a bank inspection result with a SoundbanksInfo catalog.\n *\n * @param {object} bankInfo Inspect output for a soundbank.\n * @param {object} catalog `buildSoundbanksCatalog` output.\n * @returns {object} Bank/media/event annotations for the inspected bank.\n */\n static joinSoundbanksInfo(bankInfo, catalog)\n {\n return joinSoundbanksInfo(bankInfo, catalog);\n }\n\n /**\n * Compute the Wwise 32-bit id for a bank, event, switch, or language name.\n *\n * @param {string} name Wwise object name.\n * @returns {number} Unsigned 32-bit Wwise id (FNV-1 of the lowercased name).\n */\n static wwiseIdFromName(name)\n {\n return wwiseIdFromName(name);\n }\n\n /**\n * Test whether bytes look like a Wwise soundbank.\n *\n * @param {Uint8Array|ArrayBuffer|DataView} input Candidate soundbank bytes.\n * @returns {boolean} True when the BKHD header chunk is present.\n */\n static isBNK(input)\n {\n try\n {\n return isBNK(toBytes(input));\n }\n catch\n {\n return false;\n }\n }\n\n static OUTPUT_RAW = OUTPUT_RAW;\n static OUTPUT_JSON = OUTPUT_JSON;\n static OUTPUT_BNK_JSON = OUTPUT_BNK_JSON;\n static OUTPUT_MEDIA = OUTPUT_MEDIA;\n static HIRC_TYPE_NAMES = HIRC_TYPE_NAMES;\n static type = Object.freeze([ \"audio\" ]);\n static mediaTypes = Object.freeze([ \"audio\" ]);\n static inputTypes = Object.freeze([ \"bnk\" ]);\n static outputTypes = Object.freeze([ OUTPUT_RAW, OUTPUT_MEDIA ]);\n static debugOutputTypes = Object.freeze([ OUTPUT_BNK_JSON, OUTPUT_RAW ]);\n}\n\nexport default CjsBnkFormat;\n"],"names":["FORMAT_NAME","CjsBnkFormat","DEFAULT_VALUES","constructor","options","SetValues","normalizeValues","GetValues","Read","input","readWithValues","ReadAsync","Inspect","inspectWithValues","IsSupported","isSupportedWithValues","ToJSON","value","toJsonValue","read","readAsync","inspect","isSupported","extractMedia","mediaId","bytes","toBytes","metadata","toJSON","isSoundbanksInfo","parseSoundbanksInfo","buildSoundbanksCatalog","joinSoundbanksInfo","bankInfo","catalog","wwiseIdFromName","name","isBNK","OUTPUT_RAW","OUTPUT_JSON","OUTPUT_BNK_JSON","OUTPUT_MEDIA","HIRC_TYPE_NAMES","type","Object","freeze","mediaTypes","inputTypes","outputTypes","debugOutputTypes"],"mappings":";;;AAwBA,MAAMA,WAAW,GAAG,cAAc;;AAElC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,MAAMC,YAAY,CACzB;EACI,OAAO,GAAGC,cAAc;;AAExB;AACJ;AACA;AACA;AACA;AACIC,EAAAA,WAAWA,CAACC,OAAO,GAAG,EAAE,EACxB;AACI,IAAA,IAAI,CAACC,SAAS,CAACD,OAAO,CAAC;AAC3B,EAAA;;AAEA;AACJ;AACA;AACA;AACA;AACA;AACIC,EAAAA,SAASA,CAACD,OAAO,GAAG,EAAE,EACtB;AACI,IAAA,IAAI,CAAC,OAAO,GAAGE,eAAe,CAAC,IAAI,CAAC,OAAO,EAAEF,OAAO,EAAEJ,WAAW,CAAC;AAClE,IAAA,OAAO,IAAI;AACf,EAAA;;AAEA;AACJ;AACA;AACA;AACA;AACA;AACIO,EAAAA,SAASA,CAACH,OAAO,GAAG,EAAE,EACtB;IACI,OAAOE,eAAe,CAAC,IAAI,CAAC,OAAO,EAAEF,OAAO,EAAEJ,WAAW,CAAC;AAC9D,EAAA;;AAEA;AACJ;AACA;AACA;AACA;AACA;AACA;AACIQ,EAAAA,IAAIA,CAACC,KAAK,EAAEL,OAAO,GAAG,EAAE,EACxB;IACI,OAAOM,cAAc,CAACD,KAAK,EAAE,IAAI,CAACF,SAAS,CAACH,OAAO,CAAC,CAAC;AACzD,EAAA;;AAEA;AACJ;AACA;AACA;AACA;AACA;AACA;EACI,MAAMO,SAASA,CAACF,KAAK,EAAEL,OAA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I,OAAOC,eAAeA,CAACC,IAAI,EAC3B;IACI,OAAOD,eAAe,CAACC,IAAI,CAAC;AAChC,EAAA;;AAEA;AACJ;AACA;AACA;AACA;AACA;EACI,OAAOC,KAAKA,CAAC5B,KAAK,EAClB;IACI,IACA;AACI,MAAA,OAAO4B,KAAK,CAACX,OAAO,CAACjB,KAAK,CAAC,CAAC;AAChC,IAAA,CAAC,CACD,MACA;AACI,MAAA,OAAO,KAAK;AAChB,IAAA;AACJ,EAAA;EAEA,OAAO6B,UAAU,GAAGA,UAAU;EAC9B,OAAOC,WAAW,GAAGA,WAAW;EAChC,OAAOC,eAAe,GAAGA,eAAe;EACxC,OAAOC,YAAY,GAAGA,YAAY;EAClC,OAAOC,eAAe,GAAGA,eAAe;EACxC,OAAOC,IAAI,GAAGC,MAAM,CAACC,MAAM,CAAC,CAAE,OAAO,CAAE,CAAC;EACxC,OAAOC,UAAU,GAAGF,MAAM,CAACC,MAAM,CAAC,CAAE,OAAO,CAAE,CAAC;EAC9C,OAAOE,UAAU,GAAGH,MAAM,CAACC,MAAM,CAAC,CAAE,KAAK,CAAE,CAAC;EAC5C,OAAOG,WAAW,GAAGJ,MAAM,CAACC,MAAM,CAAC,CAAEP,UAAU,EAAEG,YAAY,CAAE,CAAC;EAChE,OAAOQ,gBAAgB,GAAGL,MAAM,CAACC,MAAM,CAAC,CAAEL,eAAe,EAAEF,UAAU,CAAE,CAAC;AAC5E;;;;"}
|
|
1
|
+
{"version":3,"file":"CjsBnkFormat.js","sources":["../../../../src/formats/bnk/CjsBnkFormat.js"],"sourcesContent":["import {\r\n buildSoundbanksCatalog,\r\n isSoundbanksInfo,\r\n joinSoundbanksInfo,\r\n parseSoundbanksInfo,\r\n wwiseIdFromName\r\n} from \"./core/soundbanksInfo.js\";\r\nimport {\r\n DEFAULT_VALUES,\r\n HIRC_TYPE_NAMES,\r\n OUTPUT_BNK_JSON,\r\n OUTPUT_JSON,\r\n OUTPUT_MEDIA,\r\n OUTPUT_RAW,\r\n extractMedia,\r\n inspectWithValues,\r\n isBNK,\r\n isSupportedWithValues,\r\n normalizeValues,\r\n readWithValues,\r\n toBytes,\r\n toJsonValue\r\n} from \"./core/helpers.js\";\r\nimport { eventMediaFromBanks } from \"./core/graph.js\";\r\nimport {\r\n musicNodesFromBanks,\r\n parseMusicPlaylist,\r\n parseMusicSegment,\r\n parseMusicSwitch,\r\n parseMusicTrack\r\n} from \"./core/musicNodes.js\";\r\n\r\nconst FORMAT_NAME = \"CjsBnkFormat\";\r\n\r\n/**\r\n * Reader for Audiokinetic Wwise soundbank (.bnk) containers.\r\n *\r\n * Inspection decodes the bank header, embedded media index, object hierarchy\r\n * listing (with version-stable typed fields), and referenced bank names\r\n * without copying payloads. Read can emit the raw bank, debug JSON, or the\r\n * embedded media items undecoded. The read path stays a pure container\r\n * reader; the Wwise-domain toolkit (SoundbanksInfo catalog helpers, id hash,\r\n * event -> media graph resolution) is grouped under the `wwise` static.\r\n */\r\nexport class CjsBnkFormat\r\n{\r\n #values = DEFAULT_VALUES;\r\n\r\n /**\r\n * Create a reusable bnk format profile.\r\n *\r\n * @param {object} [options] Default read/inspect options.\r\n */\r\n constructor(options = {})\r\n {\r\n this.SetValues(options);\r\n }\r\n\r\n /**\r\n * Merge options into this profile.\r\n *\r\n * @param {object} [options] Values to merge.\r\n * @returns {CjsBnkFormat} This format profile.\r\n */\r\n SetValues(options = {})\r\n {\r\n this.#values = normalizeValues(this.#values, options, FORMAT_NAME);\r\n return this;\r\n }\r\n\r\n /**\r\n * Get normalized profile values with optional per-call overrides.\r\n *\r\n * @param {object} [options] Per-call values.\r\n * @returns {object} Normalized read values.\r\n */\r\n GetValues(options = {})\r\n {\r\n return normalizeValues(this.#values, options, FORMAT_NAME);\r\n }\r\n\r\n /**\r\n * Read soundbank bytes with this profile.\r\n *\r\n * @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.\r\n * @param {object} [options] Per-call values.\r\n * @returns {object} GPU-free raw/debug/media payload for the selected emit target.\r\n */\r\n Read(input, options = {})\r\n {\r\n return readWithValues(input, this.GetValues(options));\r\n }\r\n\r\n /**\r\n * Read soundbank bytes asynchronously with this profile.\r\n *\r\n * @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.\r\n * @param {object} [options] Per-call values.\r\n * @returns {Promise<object>} GPU-free raw/debug/media payload for the selected emit target.\r\n */\r\n async ReadAsync(input, options = {})\r\n {\r\n return this.Read(input, options);\r\n }\r\n\r\n /**\r\n * Inspect soundbank bytes without copying media payloads.\r\n *\r\n * @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.\r\n * @param {object} [options] Per-call values.\r\n * @returns {object} Soundbank metadata.\r\n */\r\n Inspect(input, options = {})\r\n {\r\n return inspectWithValues(input, this.GetValues(options));\r\n }\r\n\r\n /**\r\n * Report whether soundbank input and requested output variants are supported.\r\n *\r\n * @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.\r\n * @param {object} [options] Per-call values.\r\n * @returns {object} Support/probe report.\r\n */\r\n IsSupported(input, options = {})\r\n {\r\n return isSupportedWithValues(input, this.GetValues(options));\r\n }\r\n\r\n /**\r\n * Convert format output into JSON-compatible debug data.\r\n *\r\n * @param {any} value Format output.\r\n * @returns {any} JSON-compatible value.\r\n */\r\n ToJSON(value)\r\n {\r\n return toJsonValue(value);\r\n }\r\n\r\n /**\r\n * One-shot soundbank read.\r\n *\r\n * @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.\r\n * @param {object} [options] Read options.\r\n * @returns {object} GPU-free raw/debug/media payload for the selected emit target.\r\n */\r\n static read(input, options = {})\r\n {\r\n return readWithValues(input, normalizeValues(DEFAULT_VALUES, options, FORMAT_NAME));\r\n }\r\n\r\n /**\r\n * One-shot asynchronous soundbank read.\r\n *\r\n * @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.\r\n * @param {object} [options] Read options.\r\n * @returns {Promise<object>} GPU-free raw/debug/media payload for the selected emit target.\r\n */\r\n static async readAsync(input, options = {})\r\n {\r\n return CjsBnkFormat.read(input, options);\r\n }\r\n\r\n /**\r\n * One-shot soundbank inspection.\r\n *\r\n * @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.\r\n * @param {object} [options] Inspect options.\r\n * @returns {object} Soundbank metadata.\r\n */\r\n static inspect(input, options = {})\r\n {\r\n return inspectWithValues(input, normalizeValues(DEFAULT_VALUES, options, FORMAT_NAME));\r\n }\r\n\r\n /**\r\n * One-shot soundbank support probe.\r\n *\r\n * @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.\r\n * @param {object} [options] Probe options.\r\n * @returns {object} Support/probe report.\r\n */\r\n static isSupported(input, options = {})\r\n {\r\n return isSupportedWithValues(input, normalizeValues(DEFAULT_VALUES, options, FORMAT_NAME));\r\n }\r\n\r\n /**\r\n * Extract embedded media payloads as views over the soundbank bytes.\r\n *\r\n * @param {Uint8Array|ArrayBuffer|DataView} input Soundbank bytes.\r\n * @param {number} [mediaId] Optional single media id filter.\r\n * @returns {Array<object>} Extracted media items with undecoded bytes.\r\n */\r\n static extractMedia(input, mediaId)\r\n {\r\n const bytes = toBytes(input);\r\n const metadata = inspectWithValues(bytes, DEFAULT_VALUES);\r\n return extractMedia(bytes, metadata, mediaId);\r\n }\r\n\r\n /**\r\n * Convert format output into JSON-compatible debug data.\r\n *\r\n * @param {any} value Format output.\r\n * @returns {any} JSON-compatible value.\r\n */\r\n static toJSON(value)\r\n {\r\n return toJsonValue(value);\r\n }\r\n\r\n /**\r\n * Test whether bytes look like a Wwise soundbank.\r\n *\r\n * @param {Uint8Array|ArrayBuffer|DataView} input Candidate soundbank bytes.\r\n * @returns {boolean} True when the BKHD header chunk is present.\r\n */\r\n static isBNK(input)\r\n {\r\n try\r\n {\r\n return isBNK(toBytes(input));\r\n }\r\n catch\r\n {\r\n return false;\r\n }\r\n }\r\n\r\n /**\r\n * Wwise-domain toolkit, grouped apart from the container-reading statics -\r\n * the single home for the SoundbanksInfo catalog helpers\r\n * (`isSoundbanksInfo`, `parseSoundbanksInfo`, `buildSoundbanksCatalog`,\r\n * `joinSoundbanksInfo`), the id hash (`wwiseIdFromName`, FNV-1 of the\r\n * lowercased name), and event-graph resolution.\r\n *\r\n * `eventMediaFromBanks(inspections, options)` is graph interpretation over\r\n * `inspect()` results, not a read path: banks may split events from their\r\n * target objects (EVE keeps all events in one bank and their sounds in\r\n * others), so always pass every related bank to one call. Returns\r\n * `{ eventMedia: Map<eventObjectId, Set<wemId>>, diagnostics }`. See\r\n * core/graph.js for the walk policy.\r\n *\r\n * The interactive-music decoders (`musicNodesFromBanks` and the per-type\r\n * `parseMusicSegment/Track/Playlist/Switch`) turn the music-hierarchy\r\n * entries (HIRC 10-13) into typed nodes - children, meter, cue markers,\r\n * clips, playlist trees, decision trees, and transition rules. See\r\n * core/musicNodes.js for the anchored, exact-end-validated parse.\r\n */\r\n static wwise = Object.freeze({\r\n isSoundbanksInfo,\r\n parseSoundbanksInfo,\r\n buildSoundbanksCatalog,\r\n joinSoundbanksInfo,\r\n wwiseIdFromName,\r\n eventMediaFromBanks,\r\n musicNodesFromBanks,\r\n parseMusicSegment,\r\n parseMusicTrack,\r\n parseMusicPlaylist,\r\n parseMusicSwitch\r\n });\r\n\r\n /**\r\n * Emit targets for this format (canonical frozen enum).\r\n */\r\n static Output = Object.freeze({\r\n RAW: OUTPUT_RAW,\r\n JSON: OUTPUT_JSON,\r\n BNK_JSON: OUTPUT_BNK_JSON,\r\n MEDIA: OUTPUT_MEDIA\r\n });\r\n\r\n static HIRC_TYPE_NAMES = HIRC_TYPE_NAMES;\r\n\r\n static type = Object.freeze([ \"audio\" ]);\r\n\r\n static mediaTypes = Object.freeze([ \"audio\" ]);\r\n\r\n static inputTypes = Object.freeze([ \"bnk\" ]);\r\n\r\n static outputTypes = Object.freeze([ OUTPUT_RAW, OUTPUT_MEDIA ]);\r\n\r\n static debugOutputTypes = Object.freeze([ OUTPUT_BNK_JSON, OUTPUT_RAW ]);\r\n}\r\n\r\nexport default CjsBnkFormat;\r\n"],"names":["FORMAT_NAME","CjsBnkFormat","DEFAULT_VALUES","constructor","options","SetValues","normalizeValues","GetValues","Read","input","readWithValues","ReadAsync","Inspect","inspectWithValues","IsSupported","isSupportedWithValues","ToJSON","value","toJsonValue","read","readAsync","inspect","isSupported","extractMedia","mediaId","bytes","toBytes","metadata","toJSON","isBNK","wwise","Object","freeze","isSoundbanksInfo","parseSoundbanksInfo","buildSoundbanksCatalog","joinSoundbanksInfo","wwiseIdFromName","eventMediaFromBanks","musicNodesFromBanks","parseMusicSegment","parseMusicTrack","parseMusicPlaylist","parseMusicSwitch","Output","RAW","OUTPUT_RAW","JSON","OUTPUT_JSON","BNK_JSON","OUTPUT_BNK_JSON","MEDIA","OUTPUT_MEDIA","HIRC_TYPE_NAMES","type","mediaTypes","inputTypes","outputTypes","debugOutputTypes"],"mappings":";;;;;AAgCA,MAAMA,WAAW,GAAG,cAAc;;AAElC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,MAAMC,YAAY,CACzB;EACI,OAAO,GAAGC,cAAc;;AAExB;AACJ;AACA;AACA;AACA;AACIC,EAAAA,WAAWA,CAACC,OAAO,GAAG,EAAE,EACxB;AACI,IAAA,IAAI,CAACC,SAAS,CAACD,OAAO,CAAC;AAC3B,EAAA;;AAEA;AACJ;AACA;AACA;AACA;AACA;AACIC,EAAAA,SAASA,CAACD,OAAO,GAAG,EAAE,EACtB;AACI,IAAA,IAAI,CAAC,OAAO,GAAGE,eAAe,CAAC,IAAI,CAAC,OAAO,EAAEF,OAAO,EAAEJ,WAAW,CAAC;AAClE,IAAA,OAAO,IAAI;AACf,EAAA;;AAEA;AACJ;AACA;AACA;AACA;AACA;AACIO,EAAAA,SAASA,CAACH,OAAO,GAAG,EAAE,EACtB;IACI,OAAOE,eAAe,CAAC,IAAI,CAAC,OAAO,EAAEF,OAAO,EAAEJ,WAAW,CAAC;AAC9D,EAAA;;AAEA;AACJ;AACA;AACA;AACA;AACA;AACA;AACIQ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