In Babylon.js, I was using a GlowLayer to prettify the glowing effect on my material. It is applied on the emissive map/emissive color and not on the color map/base color. So for example, if you want a drawing to glow on your color map, it can be done:
However, I tried few things in Three.js to obtain this, but never met success
I was wondering if there is a way to do so?
Also, I am adding/removing elements interactively in Vue, by watching the computed values when changed and calling methods from my Babylon/Three scenes to update the scene accordingly ; So if the glowing method can be compatible with that, that would be perfect
(ps, if it makes any difference: I’m using PBR materials, with MeshStandardMaterial.)
The glow in the red shouldn’t be there, since the emissive value of the box itself is 0. It may depend on your monitor if the effect is obvious or not, but the feature generation pass that extracts bright colors from the source image should only extract values above 1.0.
In three.js this is managed by the bloom threshold, as shown in this demo. Bloom does not only affect emissive surfaces – a strong light directed at a metallic surface would also give a bloom, for example, the source of the bright light does not matter.
For the case shown above you’d probably want to raise the threshold to around 1, and ensure you’re using a HalfFloatType (default) or FloatType render target for post-processing so input values are not clamped to [0, 1] before bloom.