@babylonjs/core 5.43.2 → 5.45.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/Audio/sound.d.ts +0 -1
- package/Audio/sound.js +10 -10
- package/Audio/sound.js.map +1 -1
- package/Cameras/Inputs/BaseCameraPointersInput.js +7 -0
- package/Cameras/Inputs/BaseCameraPointersInput.js.map +1 -1
- package/Culling/ray.js +8 -2
- package/Culling/ray.js.map +1 -1
- package/Engines/WebGPU/Extensions/engine.renderTarget.js +1 -1
- package/Engines/WebGPU/Extensions/engine.renderTarget.js.map +1 -1
- package/Engines/engine.js +11 -2
- package/Engines/engine.js.map +1 -1
- package/Engines/thinEngine.js +3 -3
- package/Engines/thinEngine.js.map +1 -1
- package/Inputs/scene.inputManager.d.ts +1 -0
- package/Inputs/scene.inputManager.js +8 -1
- package/Inputs/scene.inputManager.js.map +1 -1
- package/Loading/Plugins/babylonFileLoader.js +3 -0
- package/Loading/Plugins/babylonFileLoader.js.map +1 -1
- package/Materials/Textures/index.d.ts +1 -0
- package/Materials/Textures/index.js +1 -0
- package/Materials/Textures/index.js.map +1 -1
- package/Materials/Textures/ktx2decoderTypes.d.ts +215 -0
- package/Materials/Textures/ktx2decoderTypes.js +35 -0
- package/Materials/Textures/ktx2decoderTypes.js.map +1 -0
- package/Materials/Textures/texture.d.ts +1 -1
- package/Materials/Textures/texture.js.map +1 -1
- package/Maths/math.vector.js +155 -120
- package/Maths/math.vector.js.map +1 -1
- package/Meshes/mesh.js +9 -0
- package/Meshes/mesh.js.map +1 -1
- package/Meshes/transformNode.d.ts +9 -1
- package/Meshes/transformNode.js +22 -7
- package/Meshes/transformNode.js.map +1 -1
- package/Misc/khronosTextureContainer2.d.ts +68 -2
- package/Misc/khronosTextureContainer2.js +149 -1
- package/Misc/khronosTextureContainer2.js.map +1 -1
- package/Morph/morphTargetManager.d.ts +2 -0
- package/Morph/morphTargetManager.js +8 -0
- package/Morph/morphTargetManager.js.map +1 -1
- package/assetContainer.d.ts +16 -1
- package/assetContainer.js +198 -41
- package/assetContainer.js.map +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,215 @@
|
|
|
1
|
+
export declare enum SourceTextureFormat {
|
|
2
|
+
ETC1S = 0,
|
|
3
|
+
UASTC4x4 = 1
|
|
4
|
+
}
|
|
5
|
+
export declare enum TranscodeTarget {
|
|
6
|
+
ASTC_4X4_RGBA = 0,
|
|
7
|
+
BC7_RGBA = 1,
|
|
8
|
+
BC3_RGBA = 2,
|
|
9
|
+
BC1_RGB = 3,
|
|
10
|
+
PVRTC1_4_RGBA = 4,
|
|
11
|
+
PVRTC1_4_RGB = 5,
|
|
12
|
+
ETC2_RGBA = 6,
|
|
13
|
+
ETC1_RGB = 7,
|
|
14
|
+
RGBA32 = 8,
|
|
15
|
+
R8 = 9,
|
|
16
|
+
RG8 = 10
|
|
17
|
+
}
|
|
18
|
+
export declare enum EngineFormat {
|
|
19
|
+
COMPRESSED_RGBA_BPTC_UNORM_EXT = 36492,
|
|
20
|
+
COMPRESSED_RGBA_ASTC_4X4_KHR = 37808,
|
|
21
|
+
COMPRESSED_RGB_S3TC_DXT1_EXT = 33776,
|
|
22
|
+
COMPRESSED_RGBA_S3TC_DXT5_EXT = 33779,
|
|
23
|
+
COMPRESSED_RGBA_PVRTC_4BPPV1_IMG = 35842,
|
|
24
|
+
COMPRESSED_RGB_PVRTC_4BPPV1_IMG = 35840,
|
|
25
|
+
COMPRESSED_RGBA8_ETC2_EAC = 37496,
|
|
26
|
+
COMPRESSED_RGB8_ETC2 = 37492,
|
|
27
|
+
COMPRESSED_RGB_ETC1_WEBGL = 36196,
|
|
28
|
+
RGBA8Format = 32856,
|
|
29
|
+
R8Format = 33321,
|
|
30
|
+
RG8Format = 33323
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Leaf node of a decision tree
|
|
34
|
+
* It defines the transcoding format to use to transcode the texture as well as the corresponding format to use at the engine level when creating the texture
|
|
35
|
+
*/
|
|
36
|
+
export interface ILeaf {
|
|
37
|
+
/**
|
|
38
|
+
* The format to transcode to
|
|
39
|
+
*/
|
|
40
|
+
transcodeFormat: TranscodeTarget;
|
|
41
|
+
/**
|
|
42
|
+
* The format to use when creating the texture at the engine level after it has been transcoded to transcodeFormat
|
|
43
|
+
*/
|
|
44
|
+
engineFormat: EngineFormat;
|
|
45
|
+
/**
|
|
46
|
+
* Whether the texture must be rounded to a multiple of 4 (should normally be the case for all compressed formats). Default: true
|
|
47
|
+
*/
|
|
48
|
+
roundToMultiple4?: boolean;
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* Regular node of a decision tree
|
|
52
|
+
*
|
|
53
|
+
* Each property (except for "yes" and "no"), if not empty, will be checked in order to determine the next node to select.
|
|
54
|
+
* If all checks are successful, the "yes" node will be selected, else the "no" node will be selected.
|
|
55
|
+
*/
|
|
56
|
+
export interface INode {
|
|
57
|
+
/**
|
|
58
|
+
* The name of the capability to check. Can be one of the following:
|
|
59
|
+
* astc
|
|
60
|
+
* bptc
|
|
61
|
+
* s3tc
|
|
62
|
+
* pvrtc
|
|
63
|
+
* etc2
|
|
64
|
+
* etc1
|
|
65
|
+
*/
|
|
66
|
+
cap?: string;
|
|
67
|
+
/**
|
|
68
|
+
* The name of the option to check from the options object passed to the KTX2 decode function. {@link IKTX2DecoderOptions}
|
|
69
|
+
*/
|
|
70
|
+
option?: string;
|
|
71
|
+
/**
|
|
72
|
+
* Checks if alpha is present in the texture
|
|
73
|
+
*/
|
|
74
|
+
alpha?: boolean;
|
|
75
|
+
/**
|
|
76
|
+
* Checks the currently selected transcoding format.
|
|
77
|
+
*/
|
|
78
|
+
transcodeFormat?: TranscodeTarget | TranscodeTarget[];
|
|
79
|
+
/**
|
|
80
|
+
* Checks that the texture is a power of two
|
|
81
|
+
*/
|
|
82
|
+
needsPowerOfTwo?: boolean;
|
|
83
|
+
/**
|
|
84
|
+
* The node to select if all checks are successful
|
|
85
|
+
*/
|
|
86
|
+
yes?: INode | ILeaf;
|
|
87
|
+
/**
|
|
88
|
+
* The node to select if at least one check is not successful
|
|
89
|
+
*/
|
|
90
|
+
no?: INode | ILeaf;
|
|
91
|
+
}
|
|
92
|
+
/**
|
|
93
|
+
* Decision tree used to determine the transcoding format to use for a given source texture format
|
|
94
|
+
*/
|
|
95
|
+
export interface IDecisionTree {
|
|
96
|
+
/**
|
|
97
|
+
* textureFormat can be either UASTC or ETC1S
|
|
98
|
+
*/
|
|
99
|
+
[textureFormat: string]: INode;
|
|
100
|
+
}
|
|
101
|
+
/**
|
|
102
|
+
* Result of the KTX2 decode function
|
|
103
|
+
*/
|
|
104
|
+
export interface IDecodedData {
|
|
105
|
+
/**
|
|
106
|
+
* Width of the texture
|
|
107
|
+
*/
|
|
108
|
+
width: number;
|
|
109
|
+
/**
|
|
110
|
+
* Height of the texture
|
|
111
|
+
*/
|
|
112
|
+
height: number;
|
|
113
|
+
/**
|
|
114
|
+
* The format to use when creating the texture at the engine level
|
|
115
|
+
* This corresponds to the engineFormat property of the leaf node of the decision tree
|
|
116
|
+
*/
|
|
117
|
+
transcodedFormat: number;
|
|
118
|
+
/**
|
|
119
|
+
* List of mipmap levels.
|
|
120
|
+
* The first element is the base level, the last element is the smallest mipmap level (if more than one mipmap level is present)
|
|
121
|
+
*/
|
|
122
|
+
mipmaps: Array<IMipmap>;
|
|
123
|
+
/**
|
|
124
|
+
* Whether the texture data is in gamma space or not
|
|
125
|
+
*/
|
|
126
|
+
isInGammaSpace: boolean;
|
|
127
|
+
/**
|
|
128
|
+
* Whether the texture has an alpha channel or not
|
|
129
|
+
*/
|
|
130
|
+
hasAlpha: boolean;
|
|
131
|
+
/**
|
|
132
|
+
* The name of the transcoder used to transcode the texture
|
|
133
|
+
*/
|
|
134
|
+
transcoderName: string;
|
|
135
|
+
/**
|
|
136
|
+
* The errors (if any) encountered during the decoding process
|
|
137
|
+
*/
|
|
138
|
+
errors?: string;
|
|
139
|
+
}
|
|
140
|
+
/**
|
|
141
|
+
* Defines a mipmap level
|
|
142
|
+
*/
|
|
143
|
+
export interface IMipmap {
|
|
144
|
+
/**
|
|
145
|
+
* The data of the mipmap level
|
|
146
|
+
*/
|
|
147
|
+
data: Uint8Array | null;
|
|
148
|
+
/**
|
|
149
|
+
* The width of the mipmap level
|
|
150
|
+
*/
|
|
151
|
+
width: number;
|
|
152
|
+
/**
|
|
153
|
+
* The height of the mipmap level
|
|
154
|
+
*/
|
|
155
|
+
height: number;
|
|
156
|
+
}
|
|
157
|
+
/**
|
|
158
|
+
* The compressed texture formats supported by the browser
|
|
159
|
+
*/
|
|
160
|
+
export interface ICompressedFormatCapabilities {
|
|
161
|
+
/**
|
|
162
|
+
* Whether the browser supports ASTC
|
|
163
|
+
*/
|
|
164
|
+
astc?: boolean;
|
|
165
|
+
/**
|
|
166
|
+
* Whether the browser supports BPTC
|
|
167
|
+
*/
|
|
168
|
+
bptc?: boolean;
|
|
169
|
+
/**
|
|
170
|
+
* Whether the browser supports S3TC
|
|
171
|
+
*/
|
|
172
|
+
s3tc?: boolean;
|
|
173
|
+
/**
|
|
174
|
+
* Whether the browser supports PVRTC
|
|
175
|
+
*/
|
|
176
|
+
pvrtc?: boolean;
|
|
177
|
+
/**
|
|
178
|
+
* Whether the browser supports ETC2
|
|
179
|
+
*/
|
|
180
|
+
etc2?: boolean;
|
|
181
|
+
/**
|
|
182
|
+
* Whether the browser supports ETC1
|
|
183
|
+
*/
|
|
184
|
+
etc1?: boolean;
|
|
185
|
+
}
|
|
186
|
+
/**
|
|
187
|
+
* Options passed to the KTX2 decode function
|
|
188
|
+
*/
|
|
189
|
+
export interface IKTX2DecoderOptions {
|
|
190
|
+
/** use RGBA format if ASTC and BC7 are not available as transcoded format */
|
|
191
|
+
useRGBAIfASTCBC7NotAvailableWhenUASTC?: boolean;
|
|
192
|
+
/** force to always use (uncompressed) RGBA for transcoded format */
|
|
193
|
+
forceRGBA?: boolean;
|
|
194
|
+
/** force to always use (uncompressed) R8 for transcoded format */
|
|
195
|
+
forceR8?: boolean;
|
|
196
|
+
/** force to always use (uncompressed) RG8 for transcoded format */
|
|
197
|
+
forceRG8?: boolean;
|
|
198
|
+
/**
|
|
199
|
+
* list of transcoders to bypass when looking for a suitable transcoder. The available transcoders are:
|
|
200
|
+
* UniversalTranscoder_UASTC_ASTC
|
|
201
|
+
* UniversalTranscoder_UASTC_BC7
|
|
202
|
+
* UniversalTranscoder_UASTC_RGBA_UNORM
|
|
203
|
+
* UniversalTranscoder_UASTC_RGBA_SRGB
|
|
204
|
+
* UniversalTranscoder_UASTC_R8_UNORM
|
|
205
|
+
* UniversalTranscoder_UASTC_RG8_UNORM
|
|
206
|
+
* MSCTranscoder
|
|
207
|
+
*/
|
|
208
|
+
bypassTranscoders?: string[];
|
|
209
|
+
/**
|
|
210
|
+
* Custom decision tree to apply after the default decision tree has selected a transcoding format.
|
|
211
|
+
* Allows the user to override the default decision tree selection.
|
|
212
|
+
* The decision tree can use the INode.transcodeFormat property to base its decision on the transcoding format selected by the default decision tree.
|
|
213
|
+
*/
|
|
214
|
+
transcodeFormatDecisionTree?: IDecisionTree;
|
|
215
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
export var SourceTextureFormat;
|
|
2
|
+
(function (SourceTextureFormat) {
|
|
3
|
+
SourceTextureFormat[SourceTextureFormat["ETC1S"] = 0] = "ETC1S";
|
|
4
|
+
SourceTextureFormat[SourceTextureFormat["UASTC4x4"] = 1] = "UASTC4x4";
|
|
5
|
+
})(SourceTextureFormat || (SourceTextureFormat = {}));
|
|
6
|
+
export var TranscodeTarget;
|
|
7
|
+
(function (TranscodeTarget) {
|
|
8
|
+
TranscodeTarget[TranscodeTarget["ASTC_4X4_RGBA"] = 0] = "ASTC_4X4_RGBA";
|
|
9
|
+
TranscodeTarget[TranscodeTarget["BC7_RGBA"] = 1] = "BC7_RGBA";
|
|
10
|
+
TranscodeTarget[TranscodeTarget["BC3_RGBA"] = 2] = "BC3_RGBA";
|
|
11
|
+
TranscodeTarget[TranscodeTarget["BC1_RGB"] = 3] = "BC1_RGB";
|
|
12
|
+
TranscodeTarget[TranscodeTarget["PVRTC1_4_RGBA"] = 4] = "PVRTC1_4_RGBA";
|
|
13
|
+
TranscodeTarget[TranscodeTarget["PVRTC1_4_RGB"] = 5] = "PVRTC1_4_RGB";
|
|
14
|
+
TranscodeTarget[TranscodeTarget["ETC2_RGBA"] = 6] = "ETC2_RGBA";
|
|
15
|
+
TranscodeTarget[TranscodeTarget["ETC1_RGB"] = 7] = "ETC1_RGB";
|
|
16
|
+
TranscodeTarget[TranscodeTarget["RGBA32"] = 8] = "RGBA32";
|
|
17
|
+
TranscodeTarget[TranscodeTarget["R8"] = 9] = "R8";
|
|
18
|
+
TranscodeTarget[TranscodeTarget["RG8"] = 10] = "RG8";
|
|
19
|
+
})(TranscodeTarget || (TranscodeTarget = {}));
|
|
20
|
+
export var EngineFormat;
|
|
21
|
+
(function (EngineFormat) {
|
|
22
|
+
EngineFormat[EngineFormat["COMPRESSED_RGBA_BPTC_UNORM_EXT"] = 36492] = "COMPRESSED_RGBA_BPTC_UNORM_EXT";
|
|
23
|
+
EngineFormat[EngineFormat["COMPRESSED_RGBA_ASTC_4X4_KHR"] = 37808] = "COMPRESSED_RGBA_ASTC_4X4_KHR";
|
|
24
|
+
EngineFormat[EngineFormat["COMPRESSED_RGB_S3TC_DXT1_EXT"] = 33776] = "COMPRESSED_RGB_S3TC_DXT1_EXT";
|
|
25
|
+
EngineFormat[EngineFormat["COMPRESSED_RGBA_S3TC_DXT5_EXT"] = 33779] = "COMPRESSED_RGBA_S3TC_DXT5_EXT";
|
|
26
|
+
EngineFormat[EngineFormat["COMPRESSED_RGBA_PVRTC_4BPPV1_IMG"] = 35842] = "COMPRESSED_RGBA_PVRTC_4BPPV1_IMG";
|
|
27
|
+
EngineFormat[EngineFormat["COMPRESSED_RGB_PVRTC_4BPPV1_IMG"] = 35840] = "COMPRESSED_RGB_PVRTC_4BPPV1_IMG";
|
|
28
|
+
EngineFormat[EngineFormat["COMPRESSED_RGBA8_ETC2_EAC"] = 37496] = "COMPRESSED_RGBA8_ETC2_EAC";
|
|
29
|
+
EngineFormat[EngineFormat["COMPRESSED_RGB8_ETC2"] = 37492] = "COMPRESSED_RGB8_ETC2";
|
|
30
|
+
EngineFormat[EngineFormat["COMPRESSED_RGB_ETC1_WEBGL"] = 36196] = "COMPRESSED_RGB_ETC1_WEBGL";
|
|
31
|
+
EngineFormat[EngineFormat["RGBA8Format"] = 32856] = "RGBA8Format";
|
|
32
|
+
EngineFormat[EngineFormat["R8Format"] = 33321] = "R8Format";
|
|
33
|
+
EngineFormat[EngineFormat["RG8Format"] = 33323] = "RG8Format";
|
|
34
|
+
})(EngineFormat || (EngineFormat = {}));
|
|
35
|
+
//# sourceMappingURL=ktx2decoderTypes.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ktx2decoderTypes.js","sourceRoot":"","sources":["../../../../../lts/core/generated/Materials/Textures/ktx2decoderTypes.ts"],"names":[],"mappings":"AAAA,MAAM,CAAN,IAAY,mBAGX;AAHD,WAAY,mBAAmB;IAC3B,+DAAK,CAAA;IACL,qEAAQ,CAAA;AACZ,CAAC,EAHW,mBAAmB,KAAnB,mBAAmB,QAG9B;AAED,MAAM,CAAN,IAAY,eAYX;AAZD,WAAY,eAAe;IACvB,uEAAa,CAAA;IACb,6DAAQ,CAAA;IACR,6DAAQ,CAAA;IACR,2DAAO,CAAA;IACP,uEAAa,CAAA;IACb,qEAAY,CAAA;IACZ,+DAAS,CAAA;IACT,6DAAQ,CAAA;IACR,yDAAM,CAAA;IACN,iDAAE,CAAA;IACF,oDAAG,CAAA;AACP,CAAC,EAZW,eAAe,KAAf,eAAe,QAY1B;AAED,MAAM,CAAN,IAAY,YAaX;AAbD,WAAY,YAAY;IACpB,uGAAuC,CAAA;IACvC,mGAAqC,CAAA;IACrC,mGAAqC,CAAA;IACrC,qGAAsC,CAAA;IACtC,2GAAyC,CAAA;IACzC,yGAAwC,CAAA;IACxC,6FAAkC,CAAA;IAClC,mFAA6B,CAAA;IAC7B,6FAAkC,CAAA;IAClC,iEAAoB,CAAA;IACpB,2DAAiB,CAAA;IACjB,6DAAkB,CAAA;AACtB,CAAC,EAbW,YAAY,KAAZ,YAAY,QAavB","sourcesContent":["export enum SourceTextureFormat {\r\n ETC1S,\r\n UASTC4x4,\r\n}\r\n\r\nexport enum TranscodeTarget {\r\n ASTC_4X4_RGBA,\r\n BC7_RGBA,\r\n BC3_RGBA,\r\n BC1_RGB,\r\n PVRTC1_4_RGBA,\r\n PVRTC1_4_RGB,\r\n ETC2_RGBA,\r\n ETC1_RGB,\r\n RGBA32,\r\n R8,\r\n RG8,\r\n}\r\n\r\nexport enum EngineFormat {\r\n COMPRESSED_RGBA_BPTC_UNORM_EXT = 0x8e8c,\r\n COMPRESSED_RGBA_ASTC_4X4_KHR = 0x93b0,\r\n COMPRESSED_RGB_S3TC_DXT1_EXT = 0x83f0,\r\n COMPRESSED_RGBA_S3TC_DXT5_EXT = 0x83f3,\r\n COMPRESSED_RGBA_PVRTC_4BPPV1_IMG = 0x8c02,\r\n COMPRESSED_RGB_PVRTC_4BPPV1_IMG = 0x8c00,\r\n COMPRESSED_RGBA8_ETC2_EAC = 0x9278,\r\n COMPRESSED_RGB8_ETC2 = 0x9274,\r\n COMPRESSED_RGB_ETC1_WEBGL = 0x8d64,\r\n RGBA8Format = 0x8058,\r\n R8Format = 0x8229,\r\n RG8Format = 0x822b,\r\n}\r\n\r\n/**\r\n * Leaf node of a decision tree\r\n * It defines the transcoding format to use to transcode the texture as well as the corresponding format to use at the engine level when creating the texture\r\n */\r\nexport interface ILeaf {\r\n /**\r\n * The format to transcode to\r\n */\r\n transcodeFormat: TranscodeTarget;\r\n\r\n /**\r\n * The format to use when creating the texture at the engine level after it has been transcoded to transcodeFormat\r\n */\r\n engineFormat: EngineFormat;\r\n\r\n /**\r\n * Whether the texture must be rounded to a multiple of 4 (should normally be the case for all compressed formats). Default: true\r\n */\r\n roundToMultiple4?: boolean;\r\n}\r\n\r\n/**\r\n * Regular node of a decision tree\r\n *\r\n * Each property (except for \"yes\" and \"no\"), if not empty, will be checked in order to determine the next node to select.\r\n * If all checks are successful, the \"yes\" node will be selected, else the \"no\" node will be selected.\r\n */\r\nexport interface INode {\r\n /**\r\n * The name of the capability to check. Can be one of the following:\r\n * astc\r\n * bptc\r\n * s3tc\r\n * pvrtc\r\n * etc2\r\n * etc1\r\n */\r\n cap?: string;\r\n\r\n /**\r\n * The name of the option to check from the options object passed to the KTX2 decode function. {@link IKTX2DecoderOptions}\r\n */\r\n option?: string;\r\n\r\n /**\r\n * Checks if alpha is present in the texture\r\n */\r\n alpha?: boolean;\r\n\r\n /**\r\n * Checks the currently selected transcoding format.\r\n */\r\n transcodeFormat?: TranscodeTarget | TranscodeTarget[];\r\n\r\n /**\r\n * Checks that the texture is a power of two\r\n */\r\n needsPowerOfTwo?: boolean;\r\n\r\n /**\r\n * The node to select if all checks are successful\r\n */\r\n yes?: INode | ILeaf;\r\n\r\n /**\r\n * The node to select if at least one check is not successful\r\n */\r\n no?: INode | ILeaf;\r\n}\r\n\r\n/**\r\n * Decision tree used to determine the transcoding format to use for a given source texture format\r\n */\r\nexport interface IDecisionTree {\r\n /**\r\n * textureFormat can be either UASTC or ETC1S\r\n */\r\n [textureFormat: string]: INode;\r\n}\r\n\r\n/**\r\n * Result of the KTX2 decode function\r\n */\r\nexport interface IDecodedData {\r\n /**\r\n * Width of the texture\r\n */\r\n width: number;\r\n\r\n /**\r\n * Height of the texture\r\n */\r\n height: number;\r\n\r\n /**\r\n * The format to use when creating the texture at the engine level\r\n * This corresponds to the engineFormat property of the leaf node of the decision tree\r\n */\r\n transcodedFormat: number;\r\n\r\n /**\r\n * List of mipmap levels.\r\n * The first element is the base level, the last element is the smallest mipmap level (if more than one mipmap level is present)\r\n */\r\n mipmaps: Array<IMipmap>;\r\n\r\n /**\r\n * Whether the texture data is in gamma space or not\r\n */\r\n isInGammaSpace: boolean;\r\n\r\n /**\r\n * Whether the texture has an alpha channel or not\r\n */\r\n hasAlpha: boolean;\r\n\r\n /**\r\n * The name of the transcoder used to transcode the texture\r\n */\r\n transcoderName: string;\r\n\r\n /**\r\n * The errors (if any) encountered during the decoding process\r\n */\r\n errors?: string;\r\n}\r\n\r\n/**\r\n * Defines a mipmap level\r\n */\r\nexport interface IMipmap {\r\n /**\r\n * The data of the mipmap level\r\n */\r\n data: Uint8Array | null;\r\n\r\n /**\r\n * The width of the mipmap level\r\n */\r\n width: number;\r\n\r\n /**\r\n * The height of the mipmap level\r\n */\r\n height: number;\r\n}\r\n\r\n/**\r\n * The compressed texture formats supported by the browser\r\n */\r\nexport interface ICompressedFormatCapabilities {\r\n /**\r\n * Whether the browser supports ASTC\r\n */\r\n astc?: boolean;\r\n\r\n /**\r\n * Whether the browser supports BPTC\r\n */\r\n bptc?: boolean;\r\n\r\n /**\r\n * Whether the browser supports S3TC\r\n */\r\n s3tc?: boolean;\r\n\r\n /**\r\n * Whether the browser supports PVRTC\r\n */\r\n pvrtc?: boolean;\r\n\r\n /**\r\n * Whether the browser supports ETC2\r\n */\r\n etc2?: boolean;\r\n\r\n /**\r\n * Whether the browser supports ETC1\r\n */\r\n etc1?: boolean;\r\n}\r\n\r\n/**\r\n * Options passed to the KTX2 decode function\r\n */\r\nexport interface IKTX2DecoderOptions {\r\n /** use RGBA format if ASTC and BC7 are not available as transcoded format */\r\n useRGBAIfASTCBC7NotAvailableWhenUASTC?: boolean;\r\n\r\n /** force to always use (uncompressed) RGBA for transcoded format */\r\n forceRGBA?: boolean;\r\n\r\n /** force to always use (uncompressed) R8 for transcoded format */\r\n forceR8?: boolean;\r\n\r\n /** force to always use (uncompressed) RG8 for transcoded format */\r\n forceRG8?: boolean;\r\n\r\n /**\r\n * list of transcoders to bypass when looking for a suitable transcoder. The available transcoders are:\r\n * UniversalTranscoder_UASTC_ASTC\r\n * UniversalTranscoder_UASTC_BC7\r\n * UniversalTranscoder_UASTC_RGBA_UNORM\r\n * UniversalTranscoder_UASTC_RGBA_SRGB\r\n * UniversalTranscoder_UASTC_R8_UNORM\r\n * UniversalTranscoder_UASTC_RG8_UNORM\r\n * MSCTranscoder\r\n */\r\n bypassTranscoders?: string[];\r\n\r\n /**\r\n * Custom decision tree to apply after the default decision tree has selected a transcoding format.\r\n * Allows the user to override the default decision tree selection.\r\n * The decision tree can use the INode.transcodeFormat property to base its decision on the transcoding format selected by the default decision tree.\r\n */\r\n transcodeFormatDecisionTree?: IDecisionTree;\r\n}\r\n"]}
|
|
@@ -281,7 +281,7 @@ export declare class Texture extends BaseTexture {
|
|
|
281
281
|
* @param onLoad callback called when the texture is loaded (defaults to null)
|
|
282
282
|
* @param forcedExtension defines the extension to use to pick the right loader
|
|
283
283
|
*/
|
|
284
|
-
updateURL(url: string, buffer?: Nullable<string | ArrayBuffer | ArrayBufferView | HTMLImageElement | Blob>, onLoad?: () => void, forcedExtension?: string): void;
|
|
284
|
+
updateURL(url: string, buffer?: Nullable<string | ArrayBuffer | ArrayBufferView | HTMLImageElement | Blob | ImageBitmap>, onLoad?: () => void, forcedExtension?: string): void;
|
|
285
285
|
/**
|
|
286
286
|
* Finish the loading sequence of a texture flagged as delayed load.
|
|
287
287
|
* @internal
|