mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-06 22:47:29 -06:00
Fix workaround for GLTF loading
CURA-6739
This commit is contained in:
parent
cadbde7b92
commit
b67944cac1
1 changed files with 1 additions and 2 deletions
|
@ -90,8 +90,7 @@ class TrimeshReader(MeshReader):
|
||||||
# doesn't like it. For some reason, this seems to happen with 3.5.7, but not 3.7.1. Below is a workaround to
|
# doesn't like it. For some reason, this seems to happen with 3.5.7, but not 3.7.1. Below is a workaround to
|
||||||
# pass a file object that has been opened with "r" instead "rb" to load a GLTF file.
|
# pass a file object that has been opened with "r" instead "rb" to load a GLTF file.
|
||||||
if file_name.endswith(".gltf"):
|
if file_name.endswith(".gltf"):
|
||||||
mesh_or_scene = trimesh.load(open(file_name, "r", encoding="utf-8"),
|
mesh_or_scene = trimesh.load(open(file_name, "r", encoding = "utf-8"), file_type = "gltf")
|
||||||
file_type = file_name.split(".")[-1].lower())
|
|
||||||
else:
|
else:
|
||||||
mesh_or_scene = trimesh.load(file_name)
|
mesh_or_scene = trimesh.load(file_name)
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue