@babylonjs/loaders 5.0.0-rc.5 → 5.0.0-rc.9

Sign up to get free protection for your applications and to get access to all the features.
Files changed (115) hide show
  1. package/OBJ/index.d.ts +4 -4
  2. package/OBJ/index.js +4 -4
  3. package/OBJ/mtlFileLoader.d.ts +41 -41
  4. package/OBJ/mtlFileLoader.js +232 -232
  5. package/OBJ/objFileLoader.d.ts +126 -126
  6. package/OBJ/objFileLoader.js +296 -296
  7. package/OBJ/objLoadingOptions.d.ts +43 -43
  8. package/OBJ/objLoadingOptions.js +1 -1
  9. package/OBJ/solidParser.d.ts +154 -154
  10. package/OBJ/solidParser.js +693 -693
  11. package/STL/index.d.ts +1 -1
  12. package/STL/index.js +1 -1
  13. package/STL/stlFileLoader.d.ts +64 -64
  14. package/STL/stlFileLoader.js +233 -233
  15. package/glTF/1.0/glTFBinaryExtension.d.ts +13 -13
  16. package/glTF/1.0/glTFBinaryExtension.js +60 -60
  17. package/glTF/1.0/glTFLoader.d.ts +136 -136
  18. package/glTF/1.0/glTFLoader.js +1815 -1815
  19. package/glTF/1.0/glTFLoaderInterfaces.d.ts +412 -412
  20. package/glTF/1.0/glTFLoaderInterfaces.js +95 -95
  21. package/glTF/1.0/glTFLoaderUtils.d.ts +62 -62
  22. package/glTF/1.0/glTFLoaderUtils.js +250 -250
  23. package/glTF/1.0/glTFMaterialsCommonExtension.d.ts +10 -10
  24. package/glTF/1.0/glTFMaterialsCommonExtension.js +129 -129
  25. package/glTF/1.0/index.d.ts +5 -5
  26. package/glTF/1.0/index.js +5 -5
  27. package/glTF/2.0/Extensions/EXT_lights_image_based.d.ts +43 -43
  28. package/glTF/2.0/Extensions/EXT_lights_image_based.js +117 -117
  29. package/glTF/2.0/Extensions/EXT_mesh_gpu_instancing.d.ts +36 -36
  30. package/glTF/2.0/Extensions/EXT_mesh_gpu_instancing.js +88 -88
  31. package/glTF/2.0/Extensions/EXT_meshopt_compression.d.ts +34 -34
  32. package/glTF/2.0/Extensions/EXT_meshopt_compression.js +49 -49
  33. package/glTF/2.0/Extensions/EXT_texture_webp.d.ts +29 -29
  34. package/glTF/2.0/Extensions/EXT_texture_webp.js +40 -40
  35. package/glTF/2.0/Extensions/ExtrasAsMetadata.d.ts +50 -50
  36. package/glTF/2.0/Extensions/ExtrasAsMetadata.js +73 -73
  37. package/glTF/2.0/Extensions/KHR_draco_mesh_compression.d.ts +39 -39
  38. package/glTF/2.0/Extensions/KHR_draco_mesh_compression.js +112 -112
  39. package/glTF/2.0/Extensions/KHR_lights_punctual.d.ts +36 -36
  40. package/glTF/2.0/Extensions/KHR_lights_punctual.js +89 -89
  41. package/glTF/2.0/Extensions/KHR_materials_clearcoat.d.ts +39 -39
  42. package/glTF/2.0/Extensions/KHR_materials_clearcoat.js +94 -94
  43. package/glTF/2.0/Extensions/KHR_materials_emissive_strength.d.ts +38 -38
  44. package/glTF/2.0/Extensions/KHR_materials_emissive_strength.js +53 -53
  45. package/glTF/2.0/Extensions/KHR_materials_ior.d.ts +42 -42
  46. package/glTF/2.0/Extensions/KHR_materials_ior.js +62 -62
  47. package/glTF/2.0/Extensions/KHR_materials_pbrSpecularGlossiness.d.ts +38 -38
  48. package/glTF/2.0/Extensions/KHR_materials_pbrSpecularGlossiness.js +80 -80
  49. package/glTF/2.0/Extensions/KHR_materials_sheen.d.ts +39 -39
  50. package/glTF/2.0/Extensions/KHR_materials_sheen.js +84 -84
  51. package/glTF/2.0/Extensions/KHR_materials_specular.d.ts +38 -38
  52. package/glTF/2.0/Extensions/KHR_materials_specular.js +74 -74
  53. package/glTF/2.0/Extensions/KHR_materials_translucency.d.ts +39 -39
  54. package/glTF/2.0/Extensions/KHR_materials_translucency.js +83 -83
  55. package/glTF/2.0/Extensions/KHR_materials_transmission.d.ts +38 -38
  56. package/glTF/2.0/Extensions/KHR_materials_transmission.js +288 -288
  57. package/glTF/2.0/Extensions/KHR_materials_unlit.d.ts +38 -38
  58. package/glTF/2.0/Extensions/KHR_materials_unlit.js +73 -73
  59. package/glTF/2.0/Extensions/KHR_materials_variants.d.ts +87 -87
  60. package/glTF/2.0/Extensions/KHR_materials_variants.js +254 -254
  61. package/glTF/2.0/Extensions/KHR_materials_volume.d.ts +39 -39
  62. package/glTF/2.0/Extensions/KHR_materials_volume.js +85 -85
  63. package/glTF/2.0/Extensions/KHR_mesh_quantization.d.ts +22 -22
  64. package/glTF/2.0/Extensions/KHR_mesh_quantization.js +23 -23
  65. package/glTF/2.0/Extensions/KHR_texture_basisu.d.ts +29 -29
  66. package/glTF/2.0/Extensions/KHR_texture_basisu.js +40 -40
  67. package/glTF/2.0/Extensions/KHR_texture_transform.d.ts +33 -33
  68. package/glTF/2.0/Extensions/KHR_texture_transform.js +61 -61
  69. package/glTF/2.0/Extensions/KHR_xmp_json_ld.d.ts +32 -32
  70. package/glTF/2.0/Extensions/KHR_xmp_json_ld.js +49 -49
  71. package/glTF/2.0/Extensions/MSFT_audio_emitter.d.ts +54 -54
  72. package/glTF/2.0/Extensions/MSFT_audio_emitter.js +240 -240
  73. package/glTF/2.0/Extensions/MSFT_lod.d.ts +109 -109
  74. package/glTF/2.0/Extensions/MSFT_lod.js +369 -369
  75. package/glTF/2.0/Extensions/MSFT_minecraftMesh.d.ts +14 -14
  76. package/glTF/2.0/Extensions/MSFT_minecraftMesh.js +36 -36
  77. package/glTF/2.0/Extensions/MSFT_sRGBFactors.d.ts +14 -14
  78. package/glTF/2.0/Extensions/MSFT_sRGBFactors.js +36 -36
  79. package/glTF/2.0/Extensions/index.d.ts +26 -26
  80. package/glTF/2.0/Extensions/index.js +26 -26
  81. package/glTF/2.0/glTFLoader.d.ts +405 -405
  82. package/glTF/2.0/glTFLoader.js +2366 -2366
  83. package/glTF/2.0/glTFLoaderExtension.d.ts +152 -152
  84. package/glTF/2.0/glTFLoaderExtension.js +1 -1
  85. package/glTF/2.0/glTFLoaderInterfaces.d.ts +211 -211
  86. package/glTF/2.0/glTFLoaderInterfaces.js +1 -1
  87. package/glTF/2.0/index.d.ts +4 -4
  88. package/glTF/2.0/index.js +4 -4
  89. package/glTF/glTFFileLoader.d.ts +433 -433
  90. package/glTF/glTFFileLoader.js +927 -927
  91. package/glTF/glTFValidation.d.ts +29 -29
  92. package/glTF/glTFValidation.js +123 -123
  93. package/glTF/index.d.ts +5 -5
  94. package/glTF/index.js +5 -5
  95. package/index.d.ts +3 -3
  96. package/index.js +3 -3
  97. package/legacy/legacy-glTF.d.ts +2 -2
  98. package/legacy/legacy-glTF.js +18 -18
  99. package/legacy/legacy-glTF1.d.ts +2 -2
  100. package/legacy/legacy-glTF1.js +14 -14
  101. package/legacy/legacy-glTF1FileLoader.d.ts +2 -2
  102. package/legacy/legacy-glTF1FileLoader.js +3 -3
  103. package/legacy/legacy-glTF2.d.ts +2 -2
  104. package/legacy/legacy-glTF2.js +32 -32
  105. package/legacy/legacy-glTF2FileLoader.d.ts +2 -2
  106. package/legacy/legacy-glTF2FileLoader.js +3 -3
  107. package/legacy/legacy-glTFFileLoader.d.ts +3 -3
  108. package/legacy/legacy-glTFFileLoader.js +4 -4
  109. package/legacy/legacy-objFileLoader.d.ts +1 -1
  110. package/legacy/legacy-objFileLoader.js +12 -12
  111. package/legacy/legacy-stlFileLoader.d.ts +1 -1
  112. package/legacy/legacy-stlFileLoader.js +12 -12
  113. package/legacy/legacy.d.ts +6 -6
  114. package/legacy/legacy.js +7 -7
  115. package/package.json +3 -3
@@ -1,29 +1,29 @@
1
- import * as GLTF2 from "babylonjs-gltf2interface";
2
- /**
3
- * Configuration for glTF validation
4
- */
5
- export interface IGLTFValidationConfiguration {
6
- /**
7
- * The url of the glTF validator.
8
- */
9
- url: string;
10
- }
11
- /**
12
- * glTF validation
13
- */
14
- export declare class GLTFValidation {
15
- /**
16
- * The configuration. Defaults to `{ url: "https://preview.babylonjs.com/gltf_validator.js" }`.
17
- */
18
- static Configuration: IGLTFValidationConfiguration;
19
- private static _LoadScriptPromise;
20
- /**
21
- * Validate a glTF asset using the glTF-Validator.
22
- * @param data The JSON of a glTF or the array buffer of a binary glTF
23
- * @param rootUrl The root url for the glTF
24
- * @param fileName The file name for the glTF
25
- * @param getExternalResource The callback to get external resources for the glTF validator
26
- * @returns A promise that resolves with the glTF validation results once complete
27
- */
28
- static ValidateAsync(data: string | ArrayBuffer, rootUrl: string, fileName: string, getExternalResource: (uri: string) => Promise<ArrayBuffer>): Promise<GLTF2.IGLTFValidationResults>;
29
- }
1
+ import * as GLTF2 from "babylonjs-gltf2interface";
2
+ /**
3
+ * Configuration for glTF validation
4
+ */
5
+ export interface IGLTFValidationConfiguration {
6
+ /**
7
+ * The url of the glTF validator.
8
+ */
9
+ url: string;
10
+ }
11
+ /**
12
+ * glTF validation
13
+ */
14
+ export declare class GLTFValidation {
15
+ /**
16
+ * The configuration. Defaults to `{ url: "https://preview.babylonjs.com/gltf_validator.js" }`.
17
+ */
18
+ static Configuration: IGLTFValidationConfiguration;
19
+ private static _LoadScriptPromise;
20
+ /**
21
+ * Validate a glTF asset using the glTF-Validator.
22
+ * @param data The JSON of a glTF or the array buffer of a binary glTF
23
+ * @param rootUrl The root url for the glTF
24
+ * @param fileName The file name for the glTF
25
+ * @param getExternalResource The callback to get external resources for the glTF validator
26
+ * @returns A promise that resolves with the glTF validation results once complete
27
+ */
28
+ static ValidateAsync(data: string | ArrayBuffer, rootUrl: string, fileName: string, getExternalResource: (uri: string) => Promise<ArrayBuffer>): Promise<GLTF2.IGLTFValidationResults>;
29
+ }
@@ -1,124 +1,124 @@
1
- import { Tools } from "@babylonjs/core/Misc/tools.js";
2
- function validateAsync(data, rootUrl, fileName, getExternalResource) {
3
- var options = {
4
- externalResourceFunction: function (uri) { return getExternalResource(uri).then(function (value) { return new Uint8Array(value); }); },
5
- };
6
- if (fileName) {
7
- options.uri = rootUrl === "file:" ? fileName : rootUrl + fileName;
8
- }
9
- return data instanceof ArrayBuffer ? GLTFValidator.validateBytes(new Uint8Array(data), options) : GLTFValidator.validateString(data, options);
10
- }
11
- /**
12
- * The worker function that gets converted to a blob url to pass into a worker.
13
- */
14
- function workerFunc() {
15
- var pendingExternalResources = [];
16
- onmessage = function (message) {
17
- var data = message.data;
18
- switch (data.id) {
19
- case "init": {
20
- importScripts(data.url);
21
- break;
22
- }
23
- case "validate": {
24
- validateAsync(data.data, data.rootUrl, data.fileName, function (uri) {
25
- return new Promise(function (resolve, reject) {
26
- var index = pendingExternalResources.length;
27
- pendingExternalResources.push({ resolve: resolve, reject: reject });
28
- postMessage({ id: "getExternalResource", index: index, uri: uri });
29
- });
30
- }).then(function (value) {
31
- postMessage({ id: "validate.resolve", value: value });
32
- }, function (reason) {
33
- postMessage({ id: "validate.reject", reason: reason });
34
- });
35
- break;
36
- }
37
- case "getExternalResource.resolve": {
38
- pendingExternalResources[data.index].resolve(data.value);
39
- break;
40
- }
41
- case "getExternalResource.reject": {
42
- pendingExternalResources[data.index].reject(data.reason);
43
- break;
44
- }
45
- }
46
- };
47
- }
48
- /**
49
- * glTF validation
50
- */
51
- var GLTFValidation = /** @class */ (function () {
52
- function GLTFValidation() {
53
- }
54
- /**
55
- * Validate a glTF asset using the glTF-Validator.
56
- * @param data The JSON of a glTF or the array buffer of a binary glTF
57
- * @param rootUrl The root url for the glTF
58
- * @param fileName The file name for the glTF
59
- * @param getExternalResource The callback to get external resources for the glTF validator
60
- * @returns A promise that resolves with the glTF validation results once complete
61
- */
62
- GLTFValidation.ValidateAsync = function (data, rootUrl, fileName, getExternalResource) {
63
- var _this = this;
64
- if (typeof Worker === "function") {
65
- return new Promise(function (resolve, reject) {
66
- var workerContent = "".concat(validateAsync, "(").concat(workerFunc, ")()");
67
- var workerBlobUrl = URL.createObjectURL(new Blob([workerContent], { type: "application/javascript" }));
68
- var worker = new Worker(workerBlobUrl);
69
- var onError = function (error) {
70
- worker.removeEventListener("error", onError);
71
- worker.removeEventListener("message", onMessage);
72
- reject(error);
73
- };
74
- var onMessage = function (message) {
75
- var data = message.data;
76
- switch (data.id) {
77
- case "getExternalResource": {
78
- getExternalResource(data.uri).then(function (value) {
79
- worker.postMessage({ id: "getExternalResource.resolve", index: data.index, value: value }, [value]);
80
- }, function (reason) {
81
- worker.postMessage({ id: "getExternalResource.reject", index: data.index, reason: reason });
82
- });
83
- break;
84
- }
85
- case "validate.resolve": {
86
- worker.removeEventListener("error", onError);
87
- worker.removeEventListener("message", onMessage);
88
- resolve(data.value);
89
- worker.terminate();
90
- break;
91
- }
92
- case "validate.reject": {
93
- worker.removeEventListener("error", onError);
94
- worker.removeEventListener("message", onMessage);
95
- reject(data.reason);
96
- worker.terminate();
97
- }
98
- }
99
- };
100
- worker.addEventListener("error", onError);
101
- worker.addEventListener("message", onMessage);
102
- worker.postMessage({ id: "init", url: _this.Configuration.url });
103
- worker.postMessage({ id: "validate", data: data, rootUrl: rootUrl, fileName: fileName });
104
- });
105
- }
106
- else {
107
- if (!this._LoadScriptPromise) {
108
- this._LoadScriptPromise = Tools.LoadScriptAsync(this.Configuration.url);
109
- }
110
- return this._LoadScriptPromise.then(function () {
111
- return validateAsync(data, rootUrl, fileName, getExternalResource);
112
- });
113
- }
114
- };
115
- /**
116
- * The configuration. Defaults to `{ url: "https://preview.babylonjs.com/gltf_validator.js" }`.
117
- */
118
- GLTFValidation.Configuration = {
119
- url: "https://preview.babylonjs.com/gltf_validator.js",
120
- };
121
- return GLTFValidation;
122
- }());
123
- export { GLTFValidation };
1
+ import { Tools } from "@babylonjs/core/Misc/tools.js";
2
+ function validateAsync(data, rootUrl, fileName, getExternalResource) {
3
+ var options = {
4
+ externalResourceFunction: function (uri) { return getExternalResource(uri).then(function (value) { return new Uint8Array(value); }); },
5
+ };
6
+ if (fileName) {
7
+ options.uri = rootUrl === "file:" ? fileName : rootUrl + fileName;
8
+ }
9
+ return data instanceof ArrayBuffer ? GLTFValidator.validateBytes(new Uint8Array(data), options) : GLTFValidator.validateString(data, options);
10
+ }
11
+ /**
12
+ * The worker function that gets converted to a blob url to pass into a worker.
13
+ */
14
+ function workerFunc() {
15
+ var pendingExternalResources = [];
16
+ onmessage = function (message) {
17
+ var data = message.data;
18
+ switch (data.id) {
19
+ case "init": {
20
+ importScripts(data.url);
21
+ break;
22
+ }
23
+ case "validate": {
24
+ validateAsync(data.data, data.rootUrl, data.fileName, function (uri) {
25
+ return new Promise(function (resolve, reject) {
26
+ var index = pendingExternalResources.length;
27
+ pendingExternalResources.push({ resolve: resolve, reject: reject });
28
+ postMessage({ id: "getExternalResource", index: index, uri: uri });
29
+ });
30
+ }).then(function (value) {
31
+ postMessage({ id: "validate.resolve", value: value });
32
+ }, function (reason) {
33
+ postMessage({ id: "validate.reject", reason: reason });
34
+ });
35
+ break;
36
+ }
37
+ case "getExternalResource.resolve": {
38
+ pendingExternalResources[data.index].resolve(data.value);
39
+ break;
40
+ }
41
+ case "getExternalResource.reject": {
42
+ pendingExternalResources[data.index].reject(data.reason);
43
+ break;
44
+ }
45
+ }
46
+ };
47
+ }
48
+ /**
49
+ * glTF validation
50
+ */
51
+ var GLTFValidation = /** @class */ (function () {
52
+ function GLTFValidation() {
53
+ }
54
+ /**
55
+ * Validate a glTF asset using the glTF-Validator.
56
+ * @param data The JSON of a glTF or the array buffer of a binary glTF
57
+ * @param rootUrl The root url for the glTF
58
+ * @param fileName The file name for the glTF
59
+ * @param getExternalResource The callback to get external resources for the glTF validator
60
+ * @returns A promise that resolves with the glTF validation results once complete
61
+ */
62
+ GLTFValidation.ValidateAsync = function (data, rootUrl, fileName, getExternalResource) {
63
+ var _this = this;
64
+ if (typeof Worker === "function") {
65
+ return new Promise(function (resolve, reject) {
66
+ var workerContent = "".concat(validateAsync, "(").concat(workerFunc, ")()");
67
+ var workerBlobUrl = URL.createObjectURL(new Blob([workerContent], { type: "application/javascript" }));
68
+ var worker = new Worker(workerBlobUrl);
69
+ var onError = function (error) {
70
+ worker.removeEventListener("error", onError);
71
+ worker.removeEventListener("message", onMessage);
72
+ reject(error);
73
+ };
74
+ var onMessage = function (message) {
75
+ var data = message.data;
76
+ switch (data.id) {
77
+ case "getExternalResource": {
78
+ getExternalResource(data.uri).then(function (value) {
79
+ worker.postMessage({ id: "getExternalResource.resolve", index: data.index, value: value }, [value]);
80
+ }, function (reason) {
81
+ worker.postMessage({ id: "getExternalResource.reject", index: data.index, reason: reason });
82
+ });
83
+ break;
84
+ }
85
+ case "validate.resolve": {
86
+ worker.removeEventListener("error", onError);
87
+ worker.removeEventListener("message", onMessage);
88
+ resolve(data.value);
89
+ worker.terminate();
90
+ break;
91
+ }
92
+ case "validate.reject": {
93
+ worker.removeEventListener("error", onError);
94
+ worker.removeEventListener("message", onMessage);
95
+ reject(data.reason);
96
+ worker.terminate();
97
+ }
98
+ }
99
+ };
100
+ worker.addEventListener("error", onError);
101
+ worker.addEventListener("message", onMessage);
102
+ worker.postMessage({ id: "init", url: _this.Configuration.url });
103
+ worker.postMessage({ id: "validate", data: data, rootUrl: rootUrl, fileName: fileName });
104
+ });
105
+ }
106
+ else {
107
+ if (!this._LoadScriptPromise) {
108
+ this._LoadScriptPromise = Tools.LoadScriptAsync(this.Configuration.url);
109
+ }
110
+ return this._LoadScriptPromise.then(function () {
111
+ return validateAsync(data, rootUrl, fileName, getExternalResource);
112
+ });
113
+ }
114
+ };
115
+ /**
116
+ * The configuration. Defaults to `{ url: "https://preview.babylonjs.com/gltf_validator.js" }`.
117
+ */
118
+ GLTFValidation.Configuration = {
119
+ url: "https://preview.babylonjs.com/gltf_validator.js",
120
+ };
121
+ return GLTFValidation;
122
+ }());
123
+ export { GLTFValidation };
124
124
  //# sourceMappingURL=glTFValidation.js.map
package/glTF/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
- export * from "./glTFFileLoader";
2
- export * from "./glTFValidation";
3
- import * as GLTF1 from "./1.0/index";
4
- import * as GLTF2 from "./2.0/index";
5
- export { GLTF1, GLTF2 };
1
+ export * from "./glTFFileLoader";
2
+ export * from "./glTFValidation";
3
+ import * as GLTF1 from "./1.0/index";
4
+ import * as GLTF2 from "./2.0/index";
5
+ export { GLTF1, GLTF2 };
package/glTF/index.js CHANGED
@@ -1,6 +1,6 @@
1
- export * from "./glTFFileLoader.js";
2
- export * from "./glTFValidation.js";
3
- import * as GLTF1 from "./1.0/index.js";
4
- import * as GLTF2 from "./2.0/index.js";
5
- export { GLTF1, GLTF2 };
1
+ export * from "./glTFFileLoader";
2
+ export * from "./glTFValidation";
3
+ import * as GLTF1 from "./1.0/index";
4
+ import * as GLTF2 from "./2.0/index";
5
+ export { GLTF1, GLTF2 };
6
6
  //# sourceMappingURL=index.js.map
package/index.d.ts CHANGED
@@ -1,3 +1,3 @@
1
- export * from "./glTF/index";
2
- export * from "./OBJ/index";
3
- export * from "./STL/index";
1
+ export * from "./glTF/index";
2
+ export * from "./OBJ/index";
3
+ export * from "./STL/index";
package/index.js CHANGED
@@ -1,4 +1,4 @@
1
- export * from "./glTF/index.js";
2
- export * from "./OBJ/index.js";
3
- export * from "./STL/index.js";
1
+ export * from "./glTF/index";
2
+ export * from "./OBJ/index";
3
+ export * from "./STL/index";
4
4
  //# sourceMappingURL=index.js.map
@@ -1,2 +1,2 @@
1
- export * from "./glTF/glTFFileLoader.js";
2
- export * from "./glTF/glTFValidation.js";
1
+ export * from "./glTF/glTFFileLoader.js";
2
+ export * from "./glTF/glTFValidation.js";
@@ -1,19 +1,19 @@
1
- import * as FileLoader from "./glTF/glTFFileLoader.js";
2
- import * as Validation from "./glTF/glTFValidation.js";
3
- /**
4
- * This is the entry point for the UMD module.
5
- * The entry point for a future ESM package should be index.ts
6
- */
7
- var globalObject = typeof global !== "undefined" ? global : typeof window !== "undefined" ? window : undefined;
8
- if (typeof globalObject !== "undefined") {
9
- globalObject.BABYLON = globalObject.BABYLON || {};
10
- for (var key in FileLoader) {
11
- globalObject.BABYLON[key] = FileLoader[key];
12
- }
13
- for (var key in Validation) {
14
- globalObject.BABYLON[key] = Validation[key];
15
- }
16
- }
17
- export * from "./glTF/glTFFileLoader.js";
18
- export * from "./glTF/glTFValidation.js";
1
+ import * as FileLoader from "./glTF/glTFFileLoader.js";
2
+ import * as Validation from "./glTF/glTFValidation.js";
3
+ /**
4
+ * This is the entry point for the UMD module.
5
+ * The entry point for a future ESM package should be index.ts
6
+ */
7
+ var globalObject = typeof global !== "undefined" ? global : typeof window !== "undefined" ? window : undefined;
8
+ if (typeof globalObject !== "undefined") {
9
+ globalObject.BABYLON = globalObject.BABYLON || {};
10
+ for (var key in FileLoader) {
11
+ globalObject.BABYLON[key] = FileLoader[key];
12
+ }
13
+ for (var key in Validation) {
14
+ globalObject.BABYLON[key] = Validation[key];
15
+ }
16
+ }
17
+ export * from "./glTF/glTFFileLoader.js";
18
+ export * from "./glTF/glTFValidation.js";
19
19
  //# sourceMappingURL=legacy-glTF.js.map
@@ -1,2 +1,2 @@
1
- import * as GLTF1 from "./glTF/1.0/index.js";
2
- export { GLTF1 };
1
+ import * as GLTF1 from "./glTF/1.0/index.js";
2
+ export { GLTF1 };
@@ -1,15 +1,15 @@
1
- import * as GLTF1 from "./glTF/1.0/index.js";
2
- /**
3
- * This is the entry point for the UMD module.
4
- * The entry point for a future ESM package should be index.ts
5
- */
6
- var globalObject = typeof global !== "undefined" ? global : typeof window !== "undefined" ? window : undefined;
7
- if (typeof globalObject !== "undefined") {
8
- globalObject.BABYLON = globalObject.BABYLON || {};
9
- globalObject.BABYLON.GLTF1 = globalObject.BABYLON.GLTF1 || {};
10
- for (var key in GLTF1) {
11
- globalObject.BABYLON.GLTF1[key] = GLTF1[key];
12
- }
13
- }
14
- export { GLTF1 };
1
+ import * as GLTF1 from "./glTF/1.0/index.js";
2
+ /**
3
+ * This is the entry point for the UMD module.
4
+ * The entry point for a future ESM package should be index.ts
5
+ */
6
+ var globalObject = typeof global !== "undefined" ? global : typeof window !== "undefined" ? window : undefined;
7
+ if (typeof globalObject !== "undefined") {
8
+ globalObject.BABYLON = globalObject.BABYLON || {};
9
+ globalObject.BABYLON.GLTF1 = globalObject.BABYLON.GLTF1 || {};
10
+ for (var key in GLTF1) {
11
+ globalObject.BABYLON.GLTF1[key] = GLTF1[key];
12
+ }
13
+ }
14
+ export { GLTF1 };
15
15
  //# sourceMappingURL=legacy-glTF1.js.map
@@ -1,2 +1,2 @@
1
- export * from "./legacy-glTF";
2
- export * from "./legacy-glTF1";
1
+ export * from "./legacy-glTF";
2
+ export * from "./legacy-glTF1";
@@ -1,4 +1,4 @@
1
- // eslint-disable-next-line import/export
2
- export * from "./legacy-glTF.js";
3
- export * from "./legacy-glTF1.js";
1
+ // eslint-disable-next-line import/export
2
+ export * from "./legacy-glTF";
3
+ export * from "./legacy-glTF1";
4
4
  //# sourceMappingURL=legacy-glTF1FileLoader.js.map
@@ -1,2 +1,2 @@
1
- import * as GLTF2 from "./glTF/2.0/index.js";
2
- export { GLTF2 };
1
+ import * as GLTF2 from "./glTF/2.0/index.js";
2
+ export { GLTF2 };
@@ -1,33 +1,33 @@
1
- import * as Extensions from "./glTF/2.0/Extensions/index.js";
2
- import * as Interfaces from "./glTF/2.0/glTFLoaderInterfaces.js";
3
- import * as GLTF2 from "./glTF/2.0/index.js";
4
- /**
5
- * This is the entry point for the UMD module.
6
- * The entry point for a future ESM package should be index.ts
7
- */
8
- var globalObject = typeof global !== "undefined" ? global : typeof window !== "undefined" ? window : undefined;
9
- if (typeof globalObject !== "undefined") {
10
- globalObject.BABYLON = globalObject.BABYLON || {};
11
- var BABYLON_1 = globalObject.BABYLON;
12
- BABYLON_1.GLTF2 = BABYLON_1.GLTF2 || {};
13
- BABYLON_1.GLTF2.Loader = BABYLON_1.GLTF2.Loader || {};
14
- BABYLON_1.GLTF2.Loader.Extensions = BABYLON_1.GLTF2.Loader.Extensions || {};
15
- var keys = [];
16
- for (var key in Extensions) {
17
- BABYLON_1.GLTF2.Loader.Extensions[key] = Extensions[key];
18
- keys.push(key);
19
- }
20
- for (var key in Interfaces) {
21
- BABYLON_1.GLTF2.Loader[key] = Interfaces[key];
22
- keys.push(key);
23
- }
24
- for (var key in GLTF2) {
25
- // Prevent Reassignment.
26
- if (keys.indexOf(key) > -1) {
27
- continue;
28
- }
29
- BABYLON_1.GLTF2[key] = GLTF2[key];
30
- }
31
- }
32
- export { GLTF2 };
1
+ import * as Extensions from "./glTF/2.0/Extensions/index.js";
2
+ import * as Interfaces from "./glTF/2.0/glTFLoaderInterfaces.js";
3
+ import * as GLTF2 from "./glTF/2.0/index.js";
4
+ /**
5
+ * This is the entry point for the UMD module.
6
+ * The entry point for a future ESM package should be index.ts
7
+ */
8
+ var globalObject = typeof global !== "undefined" ? global : typeof window !== "undefined" ? window : undefined;
9
+ if (typeof globalObject !== "undefined") {
10
+ globalObject.BABYLON = globalObject.BABYLON || {};
11
+ var BABYLON_1 = globalObject.BABYLON;
12
+ BABYLON_1.GLTF2 = BABYLON_1.GLTF2 || {};
13
+ BABYLON_1.GLTF2.Loader = BABYLON_1.GLTF2.Loader || {};
14
+ BABYLON_1.GLTF2.Loader.Extensions = BABYLON_1.GLTF2.Loader.Extensions || {};
15
+ var keys = [];
16
+ for (var key in Extensions) {
17
+ BABYLON_1.GLTF2.Loader.Extensions[key] = Extensions[key];
18
+ keys.push(key);
19
+ }
20
+ for (var key in Interfaces) {
21
+ BABYLON_1.GLTF2.Loader[key] = Interfaces[key];
22
+ keys.push(key);
23
+ }
24
+ for (var key in GLTF2) {
25
+ // Prevent Reassignment.
26
+ if (keys.indexOf(key) > -1) {
27
+ continue;
28
+ }
29
+ BABYLON_1.GLTF2[key] = GLTF2[key];
30
+ }
31
+ }
32
+ export { GLTF2 };
33
33
  //# sourceMappingURL=legacy-glTF2.js.map
@@ -1,2 +1,2 @@
1
- export * from "./legacy-glTF";
2
- export * from "./legacy-glTF2";
1
+ export * from "./legacy-glTF";
2
+ export * from "./legacy-glTF2";
@@ -1,4 +1,4 @@
1
- // eslint-disable-next-line import/export
2
- export * from "./legacy-glTF.js";
3
- export * from "./legacy-glTF2.js";
1
+ // eslint-disable-next-line import/export
2
+ export * from "./legacy-glTF";
3
+ export * from "./legacy-glTF2";
4
4
  //# sourceMappingURL=legacy-glTF2FileLoader.js.map
@@ -1,3 +1,3 @@
1
- export * from "./legacy-glTF";
2
- export * from "./legacy-glTF1";
3
- export * from "./legacy-glTF2";
1
+ export * from "./legacy-glTF";
2
+ export * from "./legacy-glTF1";
3
+ export * from "./legacy-glTF2";
@@ -1,5 +1,5 @@
1
- // eslint-disable-next-line import/export
2
- export * from "./legacy-glTF.js";
3
- export * from "./legacy-glTF1.js";
4
- export * from "./legacy-glTF2.js";
1
+ // eslint-disable-next-line import/export
2
+ export * from "./legacy-glTF";
3
+ export * from "./legacy-glTF1";
4
+ export * from "./legacy-glTF2";
5
5
  //# sourceMappingURL=legacy-glTFFileLoader.js.map
@@ -1 +1 @@
1
- export * from "./OBJ/index.js";
1
+ export * from "./OBJ/index.js";
@@ -1,13 +1,13 @@
1
- import * as Loaders from "./OBJ/index.js";
2
- /**
3
- * This is the entry point for the UMD module.
4
- * The entry point for a future ESM package should be index.ts
5
- */
6
- var globalObject = typeof global !== "undefined" ? global : typeof window !== "undefined" ? window : undefined;
7
- if (typeof globalObject !== "undefined") {
8
- for (var key in Loaders) {
9
- globalObject.BABYLON[key] = Loaders[key];
10
- }
11
- }
12
- export * from "./OBJ/index.js";
1
+ import * as Loaders from "./OBJ/index.js";
2
+ /**
3
+ * This is the entry point for the UMD module.
4
+ * The entry point for a future ESM package should be index.ts
5
+ */
6
+ var globalObject = typeof global !== "undefined" ? global : typeof window !== "undefined" ? window : undefined;
7
+ if (typeof globalObject !== "undefined") {
8
+ for (var key in Loaders) {
9
+ globalObject.BABYLON[key] = Loaders[key];
10
+ }
11
+ }
12
+ export * from "./OBJ/index.js";
13
13
  //# sourceMappingURL=legacy-objFileLoader.js.map
@@ -1 +1 @@
1
- export * from "./STL/index.js";
1
+ export * from "./STL/index.js";
@@ -1,13 +1,13 @@
1
- import * as Loaders from "./STL/index.js";
2
- /**
3
- * This is the entry point for the UMD module.
4
- * The entry point for a future ESM package should be index.ts
5
- */
6
- var globalObject = typeof global !== "undefined" ? global : typeof window !== "undefined" ? window : undefined;
7
- if (typeof globalObject !== "undefined") {
8
- for (var key in Loaders) {
9
- globalObject.BABYLON[key] = Loaders[key];
10
- }
11
- }
12
- export * from "./STL/index.js";
1
+ import * as Loaders from "./STL/index.js";
2
+ /**
3
+ * This is the entry point for the UMD module.
4
+ * The entry point for a future ESM package should be index.ts
5
+ */
6
+ var globalObject = typeof global !== "undefined" ? global : typeof window !== "undefined" ? window : undefined;
7
+ if (typeof globalObject !== "undefined") {
8
+ for (var key in Loaders) {
9
+ globalObject.BABYLON[key] = Loaders[key];
10
+ }
11
+ }
12
+ export * from "./STL/index.js";
13
13
  //# sourceMappingURL=legacy-stlFileLoader.js.map
@@ -1,6 +1,6 @@
1
- export * from "./index.js";
2
- export * from "./legacy-glTF";
3
- export * from "./legacy-glTF1";
4
- export * from "./legacy-glTF2";
5
- export * from "./legacy-objFileLoader";
6
- export * from "./legacy-stlFileLoader";
1
+ export * from "./index.js";
2
+ export * from "./legacy-glTF";
3
+ export * from "./legacy-glTF1";
4
+ export * from "./legacy-glTF2";
5
+ export * from "./legacy-objFileLoader";
6
+ export * from "./legacy-stlFileLoader";