Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Godot can't open Blender file from Blender 3.6.0 on Linux #80150

Closed
tralph3 opened this issue Aug 2, 2023 · 5 comments
Closed

Godot can't open Blender file from Blender 3.6.0 on Linux #80150

tralph3 opened this issue Aug 2, 2023 · 5 comments

Comments

@tralph3
Copy link

tralph3 commented Aug 2, 2023

Godot version

4.1.1-stable

System information

Arch Linux - RX 570 - Ryzen 5 3400G - Vulkan

Issue description

Previously, Godot was able to import Blender files after setting it up in the editor settings. My current Blender version is 3.6.0. Today for some reason, it can't import newly created Blender files. If I try to import files I had made previously, it works. They're all on the same folder, have no special characters in their names, and the permissions are all the same.

Whenever Godot tries to open the new Blender files, this is the console output:

Godot Engine v4.1.1.stable.arch_linux (c) 2007-present Juan Linietsky, Ariel Manzur & Godot Contributors.
--- Debug adapter server started ---
--- GDScript language server started ---
  modules/gltf/gltf_document.cpp:7432 - Condition "err != OK" is true. Returning: ERR_FILE_CANT_OPEN
  Error importing 'res://Blend/Levels/Loop.blend'.

I have checked the source code, and it seems to be an issue with opening the file, not necessarily the content. In Windows 10, the issue doesn't happen, and the same file is able to be opened and edited.

I have also created an inhereted scene from the Blender file on Windows, and trying to open that on Linux is also failing due to a parse error. It complains that there's an error on line 21. This is the line:

[node name="Loop" instance=ExtResource("1_1kxkb")]

The other scene files look the same, and have no problems.

I downgraded Godot to 4.1, since that's the version I'm using on Windows, but the error is still present.

Steps to reproduce

  • Create a new Blender file
  • Try to import in Godot

Minimal reproduction project

MRP.zip

@fire
Copy link
Member

fire commented Aug 2, 2023

I tested on the mac and blender 3.6.1 loads the mrp correctly.

@akien-mga akien-mga added this to the 4.2 milestone Aug 2, 2023
@akien-mga akien-mga changed the title Godot can't open Blender file Godot can't open Blender file from Blender 3.6.0 on Linux Aug 2, 2023
@akien-mga
Copy link
Member

akien-mga commented Aug 2, 2023

I can't reproduce the bug with Blender 3.6.0 on Linux.

With 3.5.1, it imports fine:

Blender 3.5.1 (hash e1ccd9d4a1d3 built 2023-04-24 23:31:15)
Read prefs: /home/akien/.config/blender/3.5/config/userpref.blend
Failed to open dir (No such file or directory): /run/user/1000/gvfs/
Read blend: /home/akien/tmp/godot/bug/MRP(4)/Loop.blend
11:13:34 | INFO: Draco mesh compression is available, use library at /home/akien/Apps/Blender/blender-3.5.1-linux-x64/3.5/python/lib/python3.10/site-packages/libextern_draco.so
11:13:34 | INFO: Starting glTF 2.0 export
11:13:34 | INFO: Extracting primitive: Cube
11:13:34 | INFO: Primitives created: 2
11:13:34 | INFO: Extracting primitive: Cube.001
11:13:34 | INFO: Primitives created: 1
11:13:34 | INFO: Extracting primitive: Cube.002
Error: Tangent space can only be computed for tris/quads, aborting
11:13:34 | WARNING: Could not calculate tangents. Please try to triangulate the mesh first.
11:13:34 | INFO: Primitives created: 1
11:13:34 | INFO: Extracting primitive: Cube.003
11:13:34 | INFO: Primitives created: 1
11:13:34 | INFO: Extracting primitive: Cube.004
11:13:34 | INFO: Primitives created: 1
11:13:34 | INFO: Extracting primitive: Cube.005
11:13:34 | INFO: Primitives created: 1
11:13:34 | INFO: Finished glTF 2.0 export in 0.02971172332763672 s


Blender quit

And likewise with 3.6.0:

Blender 3.6.0 (hash c7fc78b81ecb built 2023-06-27 08:23:50)
Read prefs: "/home/akien/.config/blender/3.6/config/userpref.blend"
Failed to open dir (No such file or directory): /run/user/1000/gvfs/
Read blend: "/home/akien/tmp/godot/bug/MRP(4)/Loop.blend"
11:15:47 | INFO: Draco mesh compression is available, use library at /home/akien/Apps/Blender/blender-3.6.0-linux-x64/3.6/python/lib/python3.10/site-packages/libextern_draco.so
11:15:47 | INFO: Starting glTF 2.0 export
11:15:47 | INFO: Extracting primitive: Cube
11:15:47 | INFO: Primitives created: 2
11:15:47 | INFO: Extracting primitive: Cube.001
11:15:47 | INFO: Primitives created: 1
11:15:47 | INFO: Extracting primitive: Cube.002
Error: Tangent space can only be computed for tris/quads, aborting
11:15:47 | WARNING: Could not calculate tangents. Please try to triangulate the mesh first.
11:15:47 | INFO: Primitives created: 1
11:15:47 | INFO: Extracting primitive: Cube.003
11:15:47 | INFO: Primitives created: 1
11:15:47 | INFO: Extracting primitive: Cube.004
11:15:47 | INFO: Primitives created: 1
11:15:47 | INFO: Extracting primitive: Cube.005
11:15:47 | INFO: Primitives created: 1
11:15:47 | INFO: Finished glTF 2.0 export in 0.02121710777282715 s


Blender quit

On the other hand, opening the Advanced Import Settings dialog triggers those errors after importing with 3.6.0:

ERROR: Condition "p_material != material_data.material" is true.
   at: _fill_material (./editor/import/scene_import_settings.cpp:171)
ERROR: Condition "p_material != material_data.material" is true.
   at: _fill_material (./editor/import/scene_import_settings.cpp:171)

While importing with 3.5.1 does not trigger these errors.

3.6.1 has the same error in the Advanced Import Settings as 3.6.0.

This is with Godot master (4.2.dev dca12c2)

@tralph3
Copy link
Author

tralph3 commented Aug 2, 2023

So this is a Blender bug? Any way to fix it in the meantime? What do you mean it starts to happen after opening the Advanced Import Settings?

@adrobisch
Copy link

Looks like a problem with the current Blender version package in Arch, see #76338 (comment)

@tralph3
Copy link
Author

tralph3 commented Aug 9, 2023

Can confirm that after updating to Blender 3.6.1, the issue is gone.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants