mirror of
https://git.datalinker.icu/kijai/ComfyUI-Hunyuan3DWrapper.git
synced 2025-12-09 21:04:32 +08:00
Fix applying PBR
This commit is contained in:
parent
e7badbe79f
commit
d454e92b9b
5
nodes.py
5
nodes.py
@ -814,6 +814,11 @@ class Hy3DSetMeshPBRTextures:
|
|||||||
CATEGORY = "Hunyuan3DWrapper"
|
CATEGORY = "Hunyuan3DWrapper"
|
||||||
|
|
||||||
def set_textures(self, mesh, image, texture):
|
def set_textures(self, mesh, image, texture):
|
||||||
|
from trimesh.visual.material import SimpleMaterial
|
||||||
|
if isinstance(mesh.visual.material, SimpleMaterial):
|
||||||
|
log.info("Found SimpleMaterial, Converting to PBRMaterial")
|
||||||
|
mesh.visual.material = mesh.visual.material.to_pbr()
|
||||||
|
|
||||||
|
|
||||||
TEXTURE_MAPPING = {
|
TEXTURE_MAPPING = {
|
||||||
'base_color': ('baseColorTexture', "Base color"),
|
'base_color': ('baseColorTexture', "Base color"),
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user