babylonjs-loaders 9.7.0 → 9.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/babylon.glTF2FileLoader.js +1 -1
- package/babylon.glTF2FileLoader.js.map +1 -1
- package/babylon.glTF2FileLoader.min.js +1 -1
- package/babylon.glTF2FileLoader.min.js.map +1 -1
- package/babylon.glTFFileLoader.js +1 -1
- package/babylon.glTFFileLoader.js.map +1 -1
- package/babylon.glTFFileLoader.min.js +1 -1
- package/babylon.glTFFileLoader.min.js.map +1 -1
- package/babylonjs.loaders.d.ts +16 -16
- package/babylonjs.loaders.js +1 -1
- package/babylonjs.loaders.js.map +1 -1
- package/babylonjs.loaders.min.js +1 -1
- package/babylonjs.loaders.min.js.map +1 -1
- package/babylonjs.loaders.module.d.ts +35 -32
- package/package.json +3 -3
package/babylonjs.loaders.d.ts
CHANGED
|
@@ -638,6 +638,11 @@ declare namespace BABYLON.GLTF2 {
|
|
|
638
638
|
* Gets the underlying material
|
|
639
639
|
*/
|
|
640
640
|
get material(): PBRMaterial;
|
|
641
|
+
/**
|
|
642
|
+
* No-op: PBRMaterial has no deferred finalization.
|
|
643
|
+
* @param _loader Unused.
|
|
644
|
+
*/
|
|
645
|
+
finalizeAsync(_loader: BABYLON.GLTF2.GLTFLoader): Promise<void>;
|
|
641
646
|
/**
|
|
642
647
|
* Whether the material should be treated as unlit
|
|
643
648
|
*/
|
|
@@ -2053,10 +2058,9 @@ declare namespace BABYLON.GLTF2 {
|
|
|
2053
2058
|
set geometryCoatNormalTextureScale(value: number);
|
|
2054
2059
|
/**
|
|
2055
2060
|
* Finalizes material properties after all loading is complete.
|
|
2056
|
-
* @param
|
|
2057
|
-
* textures are disposed and the method returns early when aborted.
|
|
2061
|
+
* @param loader The glTF loader; `loader._disposed` is polled between texture passes to bail early on dispose.
|
|
2058
2062
|
*/
|
|
2059
|
-
finalizeAsync(
|
|
2063
|
+
finalizeAsync(loader: BABYLON.GLTF2.GLTFLoader): Promise<void>;
|
|
2060
2064
|
private copySurfaceToCoatAsync;
|
|
2061
2065
|
}
|
|
2062
2066
|
|
|
@@ -2077,20 +2081,17 @@ declare namespace BABYLON.GLTF2 {
|
|
|
2077
2081
|
* Gets the underlying material
|
|
2078
2082
|
*/
|
|
2079
2083
|
readonly material: Material;
|
|
2080
|
-
/** @deprecated Use finalizeAsync instead. */
|
|
2081
|
-
finalize?(): void;
|
|
2082
2084
|
/**
|
|
2083
2085
|
* Finalizes material properties after all loading is complete.
|
|
2084
|
-
* May
|
|
2085
|
-
*
|
|
2086
|
-
*
|
|
2086
|
+
* May do async work (e.g. GPU texture processing); the returned Promise is tracked
|
|
2087
|
+
* by the loader and awaited before the COMPLETE state is reached, so callers can rely
|
|
2088
|
+
* on onCompleteObservable for fully processed materials.
|
|
2087
2089
|
*
|
|
2088
|
-
*
|
|
2089
|
-
*
|
|
2090
|
-
*
|
|
2091
|
-
* @param signal An AbortSignal that fires when the loader is disposed mid-flight.
|
|
2090
|
+
* Implementations should check `loader._disposed` between awaits to bail out early
|
|
2091
|
+
* when the loader is disposed mid-flight.
|
|
2092
|
+
* @param loader The glTF loader driving the finalize step.
|
|
2092
2093
|
*/
|
|
2093
|
-
finalizeAsync
|
|
2094
|
+
finalizeAsync(loader: BABYLON.GLTF2.GLTFLoader): Promise<void>;
|
|
2094
2095
|
/**
|
|
2095
2096
|
* Whether the material should be treated as unlit
|
|
2096
2097
|
*/
|
|
@@ -3025,8 +3026,6 @@ declare namespace BABYLON.GLTF2 {
|
|
|
3025
3026
|
export class GLTFLoader implements IGLTFLoader {
|
|
3026
3027
|
/** @internal */
|
|
3027
3028
|
readonly _completePromises: Promise<unknown>[];
|
|
3028
|
-
/** AbortController used to cancel in-flight finalizeAsync() calls when dispose() is called. */
|
|
3029
|
-
private _finalizeController;
|
|
3030
3029
|
/** @internal */
|
|
3031
3030
|
_assetContainer: Nullable<AssetContainer>;
|
|
3032
3031
|
/** Storage */
|
|
@@ -3039,7 +3038,8 @@ declare namespace BABYLON.GLTF2 {
|
|
|
3039
3038
|
_skipStartAnimationStep: boolean;
|
|
3040
3039
|
private readonly _parent;
|
|
3041
3040
|
private readonly _extensions;
|
|
3042
|
-
|
|
3041
|
+
/** @internal */
|
|
3042
|
+
_disposed: boolean;
|
|
3043
3043
|
private _rootUrl;
|
|
3044
3044
|
private _fileName;
|
|
3045
3045
|
private _uniqueRootUrl;
|