Stream of light using threejs

hey i need to show a moving beam of light through my screen.i dont want to use any models or animations.i am wondering can i do this using threejs alone.i should be able to control the color intensity and path of its motion too.

Maybe this will help: GitHub - jeromeetienne/threex.volumetricspotlight: three.js extension to provide a volumetric spot light, it’s for visualizing the cone of light.
You can set its path, using THREE.Curve(). And controlling of the color intensity, it may depend on position on the curve, or you can use tween.js or GSAP for complex animations.
Creativity is up to you :slight_smile:

Is this something like what you are looking for?

1 Like

nop i mean not just a static beam you should be a llike electric beam like hospital pulse may see a green pulse moving forward constantly through a path.hope u understand what i meant

do you mean something like this at 6:54 into the video. Strip apart everything and it is essentially a cylinder with a meshshadermaterial

1 Like

Please share a screenshot that exactly shows what you are looking for. You surely know the saying: A picture is worth a thousand words :blush: .



1 Like

hi above i shared what i intended to build.i am wondering is this possible with threejs.without creating a models and importing them

Take a look at this shader:

1 Like

@prisoner849 yes this is perfect.but is this built using threejs?

can this be built easly with threejs?

@prisoner849 had to do this to have it working in webgl1:
Screen Shot 2020-02-23 at 14.41.32


can this be built easly with threejs?

I wish more people would learn how to use google. It is such a wonderful tool, you can find almost anything there - like this tutorial