@plasius/gpu-shared 0.1.10 → 0.1.13
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 +51 -1
- package/README.md +59 -2
- package/assets/brigantine.gltf +549 -24
- package/assets/cutter.gltf +538 -0
- package/assets/harbor-dock.gltf +680 -0
- package/assets/lighthouse.gltf +604 -0
- package/dist/chunk-2FIFSBB4.js +74 -0
- package/dist/chunk-2FIFSBB4.js.map +1 -0
- package/dist/chunk-DABW627O.js +113 -0
- package/dist/chunk-DABW627O.js.map +1 -0
- package/dist/chunk-DQX4DXBR.js +369 -0
- package/dist/chunk-DQX4DXBR.js.map +1 -0
- package/dist/chunk-NCPJWLX3.js +17 -0
- package/dist/chunk-NCPJWLX3.js.map +1 -0
- package/dist/gltf-loader-WAM23F37.js +9 -0
- package/dist/index.cjs +1265 -281
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +19 -6
- package/dist/index.js.map +1 -1
- package/dist/showcase-inline-assets-B7U7VX5H.js +7 -0
- package/dist/{showcase-runtime-55OVDYWT.js → showcase-runtime-PN7N3FZY.js} +818 -239
- package/dist/showcase-runtime-PN7N3FZY.js.map +1 -0
- package/package.json +15 -1
- package/src/asset-url.js +62 -11
- package/src/feature-flags.js +1 -0
- package/src/gltf-loader.js +322 -32
- package/src/i18n.js +71 -0
- package/src/index.d.ts +115 -1
- package/src/index.js +9 -1
- package/src/showcase-inline-assets.js +3 -0
- package/src/showcase-runtime.js +924 -190
- package/src/translations/en-GB.js +55 -0
- package/dist/chunk-DGUM43GV.js +0 -11
- package/dist/chunk-OTCJ3VOK.js +0 -35
- package/dist/chunk-OTCJ3VOK.js.map +0 -1
- package/dist/chunk-QBMXJ3V2.js +0 -142
- package/dist/chunk-QBMXJ3V2.js.map +0 -1
- package/dist/gltf-loader-LKALCZAV.js +0 -8
- package/dist/showcase-runtime-55OVDYWT.js.map +0 -1
- /package/dist/{chunk-DGUM43GV.js.map → gltf-loader-WAM23F37.js.map} +0 -0
- /package/dist/{gltf-loader-LKALCZAV.js.map → showcase-inline-assets-B7U7VX5H.js.map} +0 -0
package/dist/index.js
CHANGED
|
@@ -1,7 +1,14 @@
|
|
|
1
|
+
import {
|
|
2
|
+
createGpuSharedTranslator,
|
|
3
|
+
gpuSharedEnGbTranslations,
|
|
4
|
+
gpuSharedTranslationKeys,
|
|
5
|
+
gpuSharedTranslations,
|
|
6
|
+
translateGpuSharedText
|
|
7
|
+
} from "./chunk-DABW627O.js";
|
|
1
8
|
import {
|
|
2
9
|
resolveShowcaseAssetUrl
|
|
3
|
-
} from "./chunk-
|
|
4
|
-
import "./chunk-
|
|
10
|
+
} from "./chunk-2FIFSBB4.js";
|
|
11
|
+
import "./chunk-NCPJWLX3.js";
|
|
5
12
|
|
|
6
13
|
// src/index.js
|
|
7
14
|
var showcaseFocusModes = Object.freeze([
|
|
@@ -14,23 +21,29 @@ var showcaseFocusModes = Object.freeze([
|
|
|
14
21
|
"debug"
|
|
15
22
|
]);
|
|
16
23
|
async function loadGltfModel(url) {
|
|
17
|
-
const module = await import("./gltf-loader-
|
|
24
|
+
const module = await import("./gltf-loader-WAM23F37.js");
|
|
18
25
|
return module.loadGltfModel(url);
|
|
19
26
|
}
|
|
20
27
|
async function mountGpuShowcase(options = {}) {
|
|
21
|
-
const runtimeLoader = typeof options.__runtimeLoader === "function" ? options.__runtimeLoader : () => import("./showcase-runtime-
|
|
28
|
+
const runtimeLoader = typeof options.__runtimeLoader === "function" ? options.__runtimeLoader : () => import("./showcase-runtime-PN7N3FZY.js");
|
|
22
29
|
const module = await runtimeLoader();
|
|
23
30
|
if (typeof module.mountGpuShowcase !== "function") {
|
|
24
31
|
throw new Error("showcase runtime loader must provide mountGpuShowcase.");
|
|
25
32
|
}
|
|
26
33
|
const publicOptions = { ...options };
|
|
27
34
|
delete publicOptions.__runtimeLoader;
|
|
28
|
-
|
|
35
|
+
delete publicOptions.__featureFlags;
|
|
36
|
+
return module.mountGpuShowcase(publicOptions, options.__featureFlags);
|
|
29
37
|
}
|
|
30
38
|
export {
|
|
39
|
+
createGpuSharedTranslator,
|
|
40
|
+
gpuSharedEnGbTranslations,
|
|
41
|
+
gpuSharedTranslationKeys,
|
|
42
|
+
gpuSharedTranslations,
|
|
31
43
|
loadGltfModel,
|
|
32
44
|
mountGpuShowcase,
|
|
33
45
|
resolveShowcaseAssetUrl,
|
|
34
|
-
showcaseFocusModes
|
|
46
|
+
showcaseFocusModes,
|
|
47
|
+
translateGpuSharedText
|
|
35
48
|
};
|
|
36
49
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/index.js"],"sourcesContent":["export { resolveShowcaseAssetUrl } from \"./asset-url.js\";\n\nexport const showcaseFocusModes = Object.freeze([\n \"integrated\",\n \"lighting\",\n \"cloth\",\n \"fluid\",\n \"physics\",\n \"performance\",\n \"debug\",\n]);\n\nexport async function loadGltfModel(url) {\n const module = await import(\"./gltf-loader.js\");\n return module.loadGltfModel(url);\n}\n\nexport async function mountGpuShowcase(options = {}) {\n const runtimeLoader =\n typeof options.__runtimeLoader === \"function\"\n ? options.__runtimeLoader\n : () => import(\"./showcase-runtime.js\");\n const module = await runtimeLoader();\n if (typeof module.mountGpuShowcase !== \"function\") {\n throw new Error(\"showcase runtime loader must provide mountGpuShowcase.\");\n }\n\n const publicOptions = { ...options };\n delete publicOptions.__runtimeLoader;\n return module.mountGpuShowcase(publicOptions);\n}\n"],"mappings":"
|
|
1
|
+
{"version":3,"sources":["../src/index.js"],"sourcesContent":["export { resolveShowcaseAssetUrl } from \"./asset-url.js\";\nexport {\n createGpuSharedTranslator,\n gpuSharedTranslationKeys,\n gpuSharedTranslations,\n translateGpuSharedText,\n} from \"./i18n.js\";\nexport { gpuSharedEnGbTranslations } from \"./translations/en-GB.js\";\n\nexport const showcaseFocusModes = Object.freeze([\n \"integrated\",\n \"lighting\",\n \"cloth\",\n \"fluid\",\n \"physics\",\n \"performance\",\n \"debug\",\n]);\n\nexport async function loadGltfModel(url) {\n const module = await import(\"./gltf-loader.js\");\n return module.loadGltfModel(url);\n}\n\nexport async function mountGpuShowcase(options = {}) {\n const runtimeLoader =\n typeof options.__runtimeLoader === \"function\"\n ? options.__runtimeLoader\n : () => import(\"./showcase-runtime.js\");\n const module = await runtimeLoader();\n if (typeof module.mountGpuShowcase !== \"function\") {\n throw new Error(\"showcase runtime loader must provide mountGpuShowcase.\");\n }\n\n const publicOptions = { ...options };\n delete publicOptions.__runtimeLoader;\n delete publicOptions.__featureFlags;\n return module.mountGpuShowcase(publicOptions, options.__featureFlags);\n}\n"],"mappings":";;;;;;;;;;;;;AASO,IAAM,qBAAqB,OAAO,OAAO;AAAA,EAC9C;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,CAAC;AAED,eAAsB,cAAc,KAAK;AACvC,QAAM,SAAS,MAAM,OAAO,2BAAkB;AAC9C,SAAO,OAAO,cAAc,GAAG;AACjC;AAEA,eAAsB,iBAAiB,UAAU,CAAC,GAAG;AACnD,QAAM,gBACJ,OAAO,QAAQ,oBAAoB,aAC/B,QAAQ,kBACR,MAAM,OAAO,gCAAuB;AAC1C,QAAM,SAAS,MAAM,cAAc;AACnC,MAAI,OAAO,OAAO,qBAAqB,YAAY;AACjD,UAAM,IAAI,MAAM,wDAAwD;AAAA,EAC1E;AAEA,QAAM,gBAAgB,EAAE,GAAG,QAAQ;AACnC,SAAO,cAAc;AACrB,SAAO,cAAc;AACrB,SAAO,OAAO,iBAAiB,eAAe,QAAQ,cAAc;AACtE;","names":[]}
|