godotengine / godot

Godot Engine – Multi-platform 2D and 3D game engine
https://godotengine.org
MIT License
88.84k stars 20.15k forks source link

GIProbe custom emission shader not working (unlike SpatialMaterial emission) #34281

Open phaitonican opened 4 years ago

phaitonican commented 4 years ago

Godot version: Master

OS/device including version: Linux 64Bit

Issue description: Using emission in shader (Visual Shader) does not emit light like using emission in SpatialMaterial editor when using GIProbe. Is this wanted or can I close? Or maybe I do something wrong?

Steps to reproduce:

  1. Add Shader Material to mesh and set emission color
  2. Add Spatial Material to mesh and set emission color
  3. See difference

Bildschirmfoto vom 2019-12-11 19-49-52 Bildschirmfoto vom 2019-12-11 19-50-45

Calinou commented 4 years ago

I suppose this is a bug or a GLES3 limitation, but note that GIProbe has been rewritten in the vulkan branch (which will become 4.0 in the future). The new GIProbe is much more powerful; this should hopefully become possible.

phaitonican commented 4 years ago

@Calinou I see. I was also trying to use the parallax depth in visual shader but I couldnt figure out how and I thought maybe its only possible in SpatialMaterial you maybe know something about that?

Ace-Dragon commented 4 years ago

The recent GI article on the Godot website strongly hints that many current limitations would be very difficult to resolve if the engine stayed on OpenGL-ES3, Vulkan will be what fixes many of these issues. The API is lower level and harder to work with, but you get far more possibilities in return.

KoBeWi commented 3 years ago

Can anyone still reproduce this bug in Godot 3.2.3 or any later release?

If yes, please ensure that an up-to-date Minimal Reproduction Project (MRP) is included in this report (a MRP is a zipped Godot project with the minimal elements necessary to reliably trigger the bug). You can upload ZIP files in an issue comment with a drag and drop.

rcorre commented 3 years ago

Reproduced with 3.2.3: example.zip

KoBeWi commented 3 years ago

Also valid in fb21510

leobaker202 commented 2 years ago

I suppose this is a bug or a GLES3 limitation, but note that GIProbe has been rewritten in the vulkan branch (which will become 4.0 in the future). The new GIProbe is much more powerful; this should hopefully become possible.

is Can GLES3 still be used with the GIprobe there, or no

Calinou commented 2 years ago

I opened an issue to track the 4.0 version of this issue: https://github.com/godotengine/godot/issues/64124 Note that switching the mesh's global illumination mode to Dynamic fixes the issue in 4.0, but it's much more demanding than Static.

is Can GLES3 still be used with the GIprobe there, or no

No, as the OpenGL renderer in Godot 4 is low-end oriented. Mobile platforms (even the best flagship phone out there) were never able to use GIProbe effectively in 3.x as it was too demanding.