diff --git a/editor/i18n/en/assets.js b/editor/i18n/en/assets.js
index bb400b82d0b..59d43b48615 100644
--- a/editor/i18n/en/assets.js
+++ b/editor/i18n/en/assets.js
@@ -415,6 +415,15 @@ module.exports = {
'If one is not preferred, or one is invalid for use, the time range is robustly calculated.
' +
'Some FBX generators may not export this information.',
},
+ preserveMeshInstances: {
+ name: 'Preserve Mesh Instances',
+ title:
+ 'In the FBX model, if a mesh is referenced by multiple nodes (aka, mesh instancing), whether to create only one mesh asset.
' +
+ 'If not, each reference will create a mesh asset copy.
' +
+ 'This option is by default unchecked but is checked for those models migrated from version prior to V3.9.0,
' +
+ 'since in previous versions the instances are always not preserved.
' +
+ 'This option is read-only here. To modify this option for special purpose, see manual docs.',
+ },
smartMaterialEnabled: {
name: 'Smart Material Conversion',
title: 'Convert DCC materials to engine builtin materials which match the internal lighting model.',
diff --git a/editor/i18n/zh/assets.js b/editor/i18n/zh/assets.js
index d99a137e088..48a138583a2 100644
--- a/editor/i18n/zh/assets.js
+++ b/editor/i18n/zh/assets.js
@@ -423,6 +423,10 @@ module.exports = {
name: '优先使用文件时间范围',
title: '在导出 FBX 动画时,是否优先使用 FBX 文件中记录的动画时间范围。
若不使用该时间范围或此范围不可能用,则会粗略地计算动画时间范围。有些 FBX 生产工具中可能并未导出该信息。',
},
+ preserveMeshInstances: {
+ name: '保留网格实例',
+ title: 'FBX 模型中,若网格被多个节点引用(亦称网格实例化),是否仅创建一份网格资产。
若否,每处引用都将创建一份网格资产副本。
此选项默认勾选,但那些从 v3.9.0 之前的版本迁移上来的模型会自动不勾选,因为之前版本总是不保留网格实例的。
此选项在此处仅可读取,若要进行修改,见文档手册。',
+ },
smartMaterialEnabled: {
name: '材质智能转换',
title: '将 DCC 材质转化为引擎材质, 并匹对 DCC 材质的光照模型',
diff --git a/editor/inspector/assets/fbx/fbx.js b/editor/inspector/assets/fbx/fbx.js
index ab3e90081e8..2c60fbcfe2e 100644
--- a/editor/inspector/assets/fbx/fbx.js
+++ b/editor/inspector/assets/fbx/fbx.js
@@ -14,6 +14,10 @@ exports.template = /* html */`
+
+
+
+
@@ -69,6 +73,7 @@ exports.$ = {
legacyFbxImporterCheckbox: '.legacyFbxImporter-checkbox',
animationBakeRateSelect: '.animationBakeRate-select',
preferLocalTimeSpanCheckbox: '.preferLocalTimeSpan-checkbox',
+ preserveMeshInstancesCheckbox: '.preserveMeshInstances-checkbox',
smartMaterialEnabledCheckbox: '.smartMaterialEnabled-checkbox',
smartMaterialEnabledProp: '.smart-material-prop',
};
@@ -134,6 +139,20 @@ const Elements = {
updateElementReadonly.call(panel, panel.$.animationBakeRateSelect);
},
},
+ preserveMeshInstances: {
+ update() {
+ const panel = this;
+
+ let defaultValue = true;
+ if (panel.meta.userData.fbx) {
+ defaultValue = getPropValue.call(panel, panel.meta.userData.fbx.preserveMeshInstances, defaultValue);
+ }
+
+ panel.$.preserveMeshInstancesCheckbox.value = defaultValue;
+
+ updateElementInvalid.call(panel, panel.$.preserveMeshInstancesCheckbox, 'fbx.preserveMeshInstances');
+ },
+ },
preferLocalTimeSpan: {
ready() {
const panel = this;