Reputation: 2763
I'm trying to recreate this glowing box from Beat Saber in ThreeJS:
I started by creating a shape in Blender and exporting an OBJ. I've loaded it in Three, as just a geometry:
Next I needed some lighting. I tried using a RectAreaLight, positioned inside but facing outwards, and this works alright:
My problem is that, compared with the screenshot above, it doesn't really seem like it's glowing, it just looks like a bright white triangle on a red cube. I'm not sure how to get the light to "spill" outside, like in the screenshot. Maybe I need to use a different kind of light?
Upvotes: 1
Views: 1263
Reputation: 15851
what are you looking for is done usally by pixel shaders. Take a look at glow and bloom shaders like:
https://threejs.org/examples/webgl_postprocessing_unreal_bloom.html
Upvotes: 2