This commit is contained in:
2025-05-09 00:26:14 +08:00
parent 077f0e2ad7
commit 6a15adab0f
2 changed files with 36 additions and 32 deletions

View File

@@ -113,19 +113,6 @@ class GeometryUI(ui_utils.BaseUI):
# 创建8个LOD标签页
lod_names = [f"LOD{i}" for i in range(8)]
# 定义部件名称和显示名称的映射
part_display_names = {
"Head": "头部",
"Teeth": "牙齿",
"Saliva": "牙龈",
"EyeLeft": "左眼",
"EyeRight": "右眼",
"Eyeshell": "红脸",
"Eyeslashes": "眉毛",
"EyesEdge": "眉毛",
"Body": "身体"
}
# 创建标签页和内容
for lod_name in lod_names:
# 创建标签页
@@ -139,7 +126,7 @@ class GeometryUI(ui_utils.BaseUI):
# 根据LOD级别限制显示的身体部位
if lod_name == "LOD0":
parts_to_show = ["Head", "Teeth", "Saliva", "EyeLeft", "EyeRight", "Eyeshell", "Eyeslashes", "EyesEdge", "Body"]
parts_to_show = ["*Head", "*Teeth", "Saliva", "*EyeLeft", "*EyeRight", "Eyeshell", "Eyeslashes", "EyesEdge", "Body"]
elif lod_name == "LOD1":
parts_to_show = ["Head", "Teeth", "Saliva", "EyeLeft", "EyeRight", "Eyeshell", "Eyeslashes", "EyesEdge", "Body"]
elif lod_name in ["LOD2", "LOD3"]:
@@ -155,10 +142,10 @@ class GeometryUI(ui_utils.BaseUI):
part_layout = QtWidgets.QHBoxLayout()
part_layout.setSpacing(5)
# 创建标签
label = QtWidgets.QLabel(f"{part_display_names[part]}:")
label.setMinimumWidth(40)
label.setAlignment(QtCore.Qt.AlignRight | QtCore.Qt.AlignVCenter)
# 创建标签 - 使用TEXT()获取翻译
label = QtWidgets.QLabel(f"{TEXT(part, part)}:")
label.setFixedWidth(60)
label.setAlignment(QtCore.Qt.AlignLeft | QtCore.Qt.AlignVCenter)
# 输入框
line_edit = QtWidgets.QLineEdit()
@@ -441,23 +428,10 @@ class GeometryUI(ui_utils.BaseUI):
# 连接LOD标签页的加载按钮
lod_names = [f"LOD{i}" for i in range(8)]
# 定义部件名称和显示名称的映射
part_display_names = {
"Head": "头部",
"Teeth": "牙齿",
"Saliva": "牙龈",
"EyeLeft": "左眼",
"EyeRight": "右眼",
"Eyeshell": "红脸",
"Eyeslashes": "眉毛",
"EyesEdge": "眉毛",
"Body": "身体"
}
# 根据LOD级别限制连接的身体部位
for lod_name in lod_names:
if lod_name == "LOD0":
parts_to_connect = ["Head", "Teeth", "Saliva", "EyeLeft", "EyeRight", "Eyeshell", "Eyeslashes", "EyesEdge", "Body"]
parts_to_connect = ["*Head", "*Teeth", "Saliva", "*EyeLeft", "*EyeRight", "Eyeshell", "Eyeslashes", "EyesEdge", "Body"]
elif lod_name == "LOD1":
parts_to_connect = ["Head", "Teeth", "Saliva", "EyeLeft", "EyeRight", "Eyeshell", "Eyeslashes", "EyesEdge", "Body"]
elif lod_name in ["LOD2", "LOD3"]:

View File

@@ -42,6 +42,21 @@ LANG = {
"fix_seams": "修复接缝",
"optimize_scene": "优化场景",
# 身体部位名称
"Head": " 头 部",
"*Head": "*头 部",
"Teeth": " 牙 齿",
"*Teeth": "*牙 齿",
"Saliva": " 牙 龈",
"EyeLeft": " 左 眼",
"*EyeLeft": "*左 眼",
"EyeRight": " 右 眼",
"*EyeRight": "*右 眼",
"Eyeshell": " 眼 睑",
"Eyeslashes": " 眉 毛",
"EyesEdge": " 眉 毛",
"Body": " 身 体",
# 绑定模块
"rigging_title": "绑定系统",
"presets": "预设",
@@ -149,6 +164,21 @@ LANG = {
"fix_seams": "Fix Seams",
"optimize_scene": "Optimize Scene",
# Body Parts
"Head": " Head",
"*Head": "*Head",
"Teeth": " Teeth",
"*Teeth": "*Teeth",
"Saliva": " Saliva",
"EyeLeft": " EyeLeft",
"*EyeLeft": "*EyeLeft",
"EyeRight": " EyeRight",
"*EyeRight": "*EyeRight",
"Eyeshell": " Eyeshell",
"Eyeslashes": " Eyelashes",
"EyesEdge": " Eyelashes",
"Body": " Body",
# Rigging Module
"rigging_title": "Rigging System",
"presets": "Presets",