FaceColor + GlowLayer + V4

#1

First, I want to say that I just switch to V4 and it worked perfectly well. No big corrections or adjustments needed so thanks for the amazing work!

Yet I have an error showing when using faceColor on a mesh and a GlowLayer in the scene. It doesn’t break anything but there is an issue showing in the console which I don’t understand.
Here is a playground: https://www.babylonjs-playground.com/index.html#CWPN2T#57

0 Likes

#2

Pinging @sebavan

0 Likes

#3

will be fixed by Fix vertex Alpha by sebavan · Pull Request #6191 · BabylonJS/Babylon.js · GitHub

so it should be in the next package :slight_smile:

1 Like

#4

I have found something else with the GlowLayer that you can observe in this playground: https://www.babylonjs-playground.com/#63QN3J#3

First I don’t know why but the glow is behind the ground.
And there is a conflict with the postprocess. If you toggle the depth of field, the GlowLayer will stop following the camera movement.

0 Likes

#5

If the glow is used with a pipeline, it needs to be setup there to not interfer:
pipeline.glowLayerEnabled = true;
https://www.babylonjs-playground.com/#63QN3J#4

Adding @trevordev about the weird state change in the pipeline.

0 Likes

#6

Hi @sebavan, thanks for your answer!

Unfortunately, even if we use the glowLayer from the pipeline like in your playground, the glow will still stop following the camera:

glow

0 Likes

#7

Yup Main reason I pinged @trevordev :wink:

1 Like

#8

I have made some other test and to be more precise this is linked with the depthoffield only.

As seen in this playground, with only the vignette and no depthoffield, the glowLayer is ok : https://www.babylonjs-playground.com/#63QN3J#5

0 Likes

#9

@PichouPichou thanks for the extra info, looks like the glowLayer doesn’t work when depth rendering is enabled https://playground.babylonjs.com/#6ZVKE3#11 (depthOfField enables this), I’m investigating what the right fix might be.

1 Like

#10

Created a PR here which seems to fix the issues exposed by your playgrounds apply camera render target stage prior to rendering depth by TrevorDev · Pull Request #6197 · BabylonJS/Babylon.js · GitHub

2 Likes

#11

Thanks for the fix. I will follow the update to try it! :wink:

0 Likes