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

Web export fails to display Gridmap that works well in editor and Windows export #80980

Closed
isaaccp opened this issue Aug 25, 2023 · 3 comments · Fixed by #81575
Closed

Web export fails to display Gridmap that works well in editor and Windows export #80980

isaaccp opened this issue Aug 25, 2023 · 3 comments · Fixed by #81575

Comments

@isaaccp
Copy link
Contributor

isaaccp commented Aug 25, 2023

Godot version

4.1.1-stable

System information

Godot v4.1.1.stable - Windows 10.0.22621 - Vulkan (Forward+) - dedicated GeForce GTX 1050 () - Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz (8 Threads)

Issue description

I have a project that I have been developing for a while. It uses a gridmap with a meshlib to display stages and it works fine in the editor and on Windows exports. Today I tried to run it in Web 5 for the first time and everything works okay except the gridmap is not displayed at all.

The javascript console in Chrome shows the following error 256 times:
[.WebGL-00001640BE358700] GL_INVALID_OPERATION: Vertex shader input type does not match the type of the bound vertex attribute.
(even with a single tile in the gridmap)

The problem occurs in both Chrome (116.0.5845.110 (Official Build) (64-bit) (cohort: M116_Respin)) and Firefox (116.0.3).

Scene when run from the editor:
image

Scene using Web 5 in Chrome:
image

Steps to reproduce

Run the attached scene from the editor or a Windows export and it'll display a cylinder and a gridmap (with a single tile).

Run the attached scene on a web export (e.g. by using the editor Run in Browser or doing a full web export) and only the cylinder is displayed, with the error mentioned above.

Minimal reproduction project

web5_gridmap_bug.zip

@isaaccp
Copy link
Contributor Author

isaaccp commented Aug 25, 2023

These are all the logs in the Chrome javascript console.

image

@isaaccp isaaccp changed the title Gridmap that works well in editor and Windows export fails to display in Web 5 export Web 5 export fails to display Gridmap that works well in editor and Windows export Aug 25, 2023
@baptr
Copy link
Contributor

baptr commented Aug 25, 2023

I was able to repro this in v4.2.dev2.official [da81ca6], and found that it would run and render cleanly in a web5 export if I disabled vertex_color_use_as_albedo for each material in the mesh library. Hopefully that helps narrow down the issue.

@isaaccp
Copy link
Contributor Author

isaaccp commented Aug 25, 2023

I can confirm that disabling vertex_color_use_as_albedo in the materials in the mesh library also fixes it for me (but this is not very convenient and hopefully we can have a fix that addresses the issue without having to do that).

isaaccp added a commit to isaaccp/Stuffie that referenced this issue Aug 25, 2023
@akien-mga akien-mga changed the title Web 5 export fails to display Gridmap that works well in editor and Windows export Web export fails to display Gridmap that works well in editor and Windows export Sep 12, 2023
@akien-mga akien-mga added this to the 4.2 milestone Sep 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants