@galacean/engine-loader 0.9.3 → 0.9.4
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/dist/main.js +20 -1
- package/dist/main.js.map +1 -1
- package/dist/miniprogram.js +20 -1
- package/dist/module.js +20 -1
- package/dist/module.js.map +1 -1
- package/package.json +5 -5
- package/types/gltf/extensions/KHR_materials_ior.d.ts +1 -0
- package/types/gltf/extensions/index.d.ts +1 -0
package/dist/miniprogram.js
CHANGED
|
@@ -1151,7 +1151,7 @@ var MaterialParser = /*#__PURE__*/ function(Parser1) {
|
|
|
1151
1151
|
var materials = [];
|
|
1152
1152
|
for(var i = 0; i < gltf.materials.length; i++){
|
|
1153
1153
|
var _gltf_materials_i = gltf.materials[i], _gltf_materials_i_extensions = _gltf_materials_i.extensions, extensions = _gltf_materials_i_extensions === void 0 ? {} : _gltf_materials_i_extensions, pbrMetallicRoughness = _gltf_materials_i.pbrMetallicRoughness, normalTexture = _gltf_materials_i.normalTexture, occlusionTexture = _gltf_materials_i.occlusionTexture, emissiveTexture = _gltf_materials_i.emissiveTexture, emissiveFactor = _gltf_materials_i.emissiveFactor, alphaMode = _gltf_materials_i.alphaMode, alphaCutoff = _gltf_materials_i.alphaCutoff, doubleSided = _gltf_materials_i.doubleSided, _gltf_materials_i_name = _gltf_materials_i.name, name = _gltf_materials_i_name === void 0 ? "" : _gltf_materials_i_name;
|
|
1154
|
-
var KHR_materials_unlit = extensions.KHR_materials_unlit, KHR_materials_pbrSpecularGlossiness = extensions.KHR_materials_pbrSpecularGlossiness, KHR_materials_clearcoat = extensions.KHR_materials_clearcoat, OASIS_materials_remap = extensions.OASIS_materials_remap;
|
|
1154
|
+
var KHR_materials_unlit = extensions.KHR_materials_unlit, KHR_materials_pbrSpecularGlossiness = extensions.KHR_materials_pbrSpecularGlossiness, KHR_materials_clearcoat = extensions.KHR_materials_clearcoat, KHR_materials_ior = extensions.KHR_materials_ior, OASIS_materials_remap = extensions.OASIS_materials_remap;
|
|
1155
1155
|
var material = null;
|
|
1156
1156
|
if (KHR_materials_unlit) {
|
|
1157
1157
|
material = Parser.createEngineResource("KHR_materials_unlit", KHR_materials_unlit, context);
|
|
@@ -1164,6 +1164,9 @@ var MaterialParser = /*#__PURE__*/ function(Parser1) {
|
|
|
1164
1164
|
if (KHR_materials_clearcoat) {
|
|
1165
1165
|
Parser.parseEngineResource("KHR_materials_clearcoat", KHR_materials_clearcoat, material, context);
|
|
1166
1166
|
}
|
|
1167
|
+
if (KHR_materials_ior) {
|
|
1168
|
+
Parser.parseEngineResource("KHR_materials_ior", KHR_materials_ior, material, context);
|
|
1169
|
+
}
|
|
1167
1170
|
if (pbrMetallicRoughness) {
|
|
1168
1171
|
var baseColorFactor = pbrMetallicRoughness.baseColorFactor, baseColorTexture = pbrMetallicRoughness.baseColorTexture, metallicFactor = pbrMetallicRoughness.metallicFactor, roughnessFactor = pbrMetallicRoughness.roughnessFactor, metallicRoughnessTexture = pbrMetallicRoughness.metallicRoughnessTexture;
|
|
1169
1172
|
if (baseColorFactor) {
|
|
@@ -1283,6 +1286,22 @@ KHR_materials_clearcoat = __decorate([
|
|
|
1283
1286
|
registerExtension("KHR_materials_clearcoat")
|
|
1284
1287
|
], KHR_materials_clearcoat);
|
|
1285
1288
|
|
|
1289
|
+
var KHR_materials_ior = /*#__PURE__*/ function(ExtensionParser) {
|
|
1290
|
+
_inherits(KHR_materials_ior, ExtensionParser);
|
|
1291
|
+
function KHR_materials_ior() {
|
|
1292
|
+
return ExtensionParser.apply(this, arguments);
|
|
1293
|
+
}
|
|
1294
|
+
var _proto = KHR_materials_ior.prototype;
|
|
1295
|
+
_proto.parseEngineResource = function parseEngineResource(schema, material, context) {
|
|
1296
|
+
var _schema_ior = schema.ior, ior = _schema_ior === void 0 ? 1.5 : _schema_ior;
|
|
1297
|
+
material.ior = ior;
|
|
1298
|
+
};
|
|
1299
|
+
return KHR_materials_ior;
|
|
1300
|
+
}(ExtensionParser);
|
|
1301
|
+
KHR_materials_ior = __decorate([
|
|
1302
|
+
registerExtension("KHR_materials_ior")
|
|
1303
|
+
], KHR_materials_ior);
|
|
1304
|
+
|
|
1286
1305
|
var KHR_materials_pbrSpecularGlossiness = /*#__PURE__*/ function(ExtensionParser) {
|
|
1287
1306
|
_inherits(KHR_materials_pbrSpecularGlossiness, ExtensionParser);
|
|
1288
1307
|
function KHR_materials_pbrSpecularGlossiness() {
|
package/dist/module.js
CHANGED
|
@@ -1146,7 +1146,7 @@ var MaterialParser = /*#__PURE__*/ function(Parser1) {
|
|
|
1146
1146
|
var materials = [];
|
|
1147
1147
|
for(var i = 0; i < gltf.materials.length; i++){
|
|
1148
1148
|
var _gltf_materials_i = gltf.materials[i], _gltf_materials_i_extensions = _gltf_materials_i.extensions, extensions = _gltf_materials_i_extensions === void 0 ? {} : _gltf_materials_i_extensions, pbrMetallicRoughness = _gltf_materials_i.pbrMetallicRoughness, normalTexture = _gltf_materials_i.normalTexture, occlusionTexture = _gltf_materials_i.occlusionTexture, emissiveTexture = _gltf_materials_i.emissiveTexture, emissiveFactor = _gltf_materials_i.emissiveFactor, alphaMode = _gltf_materials_i.alphaMode, alphaCutoff = _gltf_materials_i.alphaCutoff, doubleSided = _gltf_materials_i.doubleSided, _gltf_materials_i_name = _gltf_materials_i.name, name = _gltf_materials_i_name === void 0 ? "" : _gltf_materials_i_name;
|
|
1149
|
-
var KHR_materials_unlit = extensions.KHR_materials_unlit, KHR_materials_pbrSpecularGlossiness = extensions.KHR_materials_pbrSpecularGlossiness, KHR_materials_clearcoat = extensions.KHR_materials_clearcoat, OASIS_materials_remap = extensions.OASIS_materials_remap;
|
|
1149
|
+
var KHR_materials_unlit = extensions.KHR_materials_unlit, KHR_materials_pbrSpecularGlossiness = extensions.KHR_materials_pbrSpecularGlossiness, KHR_materials_clearcoat = extensions.KHR_materials_clearcoat, KHR_materials_ior = extensions.KHR_materials_ior, OASIS_materials_remap = extensions.OASIS_materials_remap;
|
|
1150
1150
|
var material = null;
|
|
1151
1151
|
if (KHR_materials_unlit) {
|
|
1152
1152
|
material = Parser.createEngineResource("KHR_materials_unlit", KHR_materials_unlit, context);
|
|
@@ -1159,6 +1159,9 @@ var MaterialParser = /*#__PURE__*/ function(Parser1) {
|
|
|
1159
1159
|
if (KHR_materials_clearcoat) {
|
|
1160
1160
|
Parser.parseEngineResource("KHR_materials_clearcoat", KHR_materials_clearcoat, material, context);
|
|
1161
1161
|
}
|
|
1162
|
+
if (KHR_materials_ior) {
|
|
1163
|
+
Parser.parseEngineResource("KHR_materials_ior", KHR_materials_ior, material, context);
|
|
1164
|
+
}
|
|
1162
1165
|
if (pbrMetallicRoughness) {
|
|
1163
1166
|
var baseColorFactor = pbrMetallicRoughness.baseColorFactor, baseColorTexture = pbrMetallicRoughness.baseColorTexture, metallicFactor = pbrMetallicRoughness.metallicFactor, roughnessFactor = pbrMetallicRoughness.roughnessFactor, metallicRoughnessTexture = pbrMetallicRoughness.metallicRoughnessTexture;
|
|
1164
1167
|
if (baseColorFactor) {
|
|
@@ -1278,6 +1281,22 @@ KHR_materials_clearcoat = __decorate([
|
|
|
1278
1281
|
registerExtension("KHR_materials_clearcoat")
|
|
1279
1282
|
], KHR_materials_clearcoat);
|
|
1280
1283
|
|
|
1284
|
+
var KHR_materials_ior = /*#__PURE__*/ function(ExtensionParser) {
|
|
1285
|
+
_inherits(KHR_materials_ior, ExtensionParser);
|
|
1286
|
+
function KHR_materials_ior() {
|
|
1287
|
+
return ExtensionParser.apply(this, arguments);
|
|
1288
|
+
}
|
|
1289
|
+
var _proto = KHR_materials_ior.prototype;
|
|
1290
|
+
_proto.parseEngineResource = function parseEngineResource(schema, material, context) {
|
|
1291
|
+
var _schema_ior = schema.ior, ior = _schema_ior === void 0 ? 1.5 : _schema_ior;
|
|
1292
|
+
material.ior = ior;
|
|
1293
|
+
};
|
|
1294
|
+
return KHR_materials_ior;
|
|
1295
|
+
}(ExtensionParser);
|
|
1296
|
+
KHR_materials_ior = __decorate([
|
|
1297
|
+
registerExtension("KHR_materials_ior")
|
|
1298
|
+
], KHR_materials_ior);
|
|
1299
|
+
|
|
1281
1300
|
var KHR_materials_pbrSpecularGlossiness = /*#__PURE__*/ function(ExtensionParser) {
|
|
1282
1301
|
_inherits(KHR_materials_pbrSpecularGlossiness, ExtensionParser);
|
|
1283
1302
|
function KHR_materials_pbrSpecularGlossiness() {
|