shadows for html5 not yet possible in Godot 4 ?
Asked Answered
B

8

0

Hello,

On godot 4,
I try to have shadows working on a html5 3d project but at now, I do not know how to do it.
My meshes have uv2, and my meshes materials cast shadows and my directional light enable has shadow enabled
In gl_compability, shadow enabled on lights seems not yet supported.

  • I have tried also with lightmapgi node but is not compatible with gl_compability mode.
  • and when i configure "rendering/renderer/rendering_method.web" to "mobile" shadows work on my godot editor device but not when i test it on the web.

I test it with also the beta chrome version which support webgpu.

For information, In godot 3, indirect light and shadows was working on html5 export.

If you have an idea it would be great.
Perhaps I have to wait that lightmapgi to be supported with gl_compability ? (I haven't found that it wil be in the earlier versions).

Thanks for your help.

Bobsled answered 17/4, 2023 at 9:31 Comment(0)
S
0

So shadows are not currently supported on the OpenGL renderer (which is used for HTML5 and compatibility modes). You didn't do anything wrong.

HTML5 and OpenGL (or WebGL) was not even supposed to make it into Godot 4.0 (they were going to wait for 4.1) but they added it in at the last minute.

Which is nice that we can start testing, but sadly it is missing a ton of features, shadows being the most important, but also stuff like full screen post-processing and other things.

Suppression answered 17/4, 2023 at 10:24 Comment(0)
B
0

Suppression thanks a lot for your explanation👍 : I will do without for the moment.
I have a lot of others things to improve and to add in this project 🤔 This game engine is so great to use...

Bobsled answered 17/4, 2023 at 11:13 Comment(0)
R
0

Suppression
Hello, Cybereality.

There is still no WebGL shadows support in godot 4.1. 🤔
What version should we wait? godot 4.2?

Luking.

Redware answered 6/8, 2023 at 19:36 Comment(0)
E
0

Redware According to this issue discussed on github, yes 4.2 https://github.com/godotengine/godot/issues/66596#issuecomment-1589943433

I too really want this feature, as I need to use the Compatibility renderer for my project. A release candidate for 4.2 is currently out, so I should test it for shadows https://godotengine.org/article/release-candidate-godot-4-2-rc-2/

Especially answered 25/11, 2023 at 21:51 Comment(0)
H
0

If anyone is still wondering: with 4.2 shadows are now supported, but 4.2 builds are also quite a bit bigger (examples from here):

Hubble answered 2/1 at 22:41 Comment(0)
B
0

Hubble You can custom build an export template dropping some modules you don't need to bring the size down.

Bison answered 3/1 at 5:42 Comment(0)
H
0

Bison
I tried that for 4.1.2 and was a bit disappointed to "only" thin the build size by two MB, even though the list of modules was quite long. You can find all builds here.

Haven't tried it for 4.2, would you expect bigger gains there?

Hubble answered 3/1 at 19:36 Comment(0)
B
0

Not really, the additional measure would likely have to be some form of packaging/compression.

Bison answered 3/1 at 22:35 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.