- Home /
Laser scanning effect
I want to create a laser scanning effect similar to this; https://www.youtube.com/watch?v=70Q5Mvnmolo
I don't want it to have a waving effect like that one; just a simple flat plane that scans the room. The tricky part is that I want it to outline every mesh object it intersects. Is there a simple way to do this for mobile?
Several possibilities - I'd try casting a series of raycasts, using a Line Renderer to display the beam itself, and perhaps creating a glowing object or particle effect to highlight any points it hits.
Thanks! I don't think I can use the linerenderer because it billboards to the camera. I need the beam to be fixed from the camera. Raycasting sounds like a good idea to detect the objects though. How would I emit particles from the raycast hit point?
How many rays? What do you mean by 'outline'? What platform?
I'm not sure how many rays I'd need to achieve the desired effect. This picture shows what I'm trying to do a bit better: http://capturelifethroughthelens.com/wp-content/uploads/2011/10/DSC_0541.jpg
The 'outline' I'm talking about is actually the hard green line you see drawn on the people and background objects. Inside the plane I just want animating clouds type of effect. This is for Androud/iOS so it needs to be cheap if possible.
$$anonymous$$y first though for the ray is to build quads for each ray and uv map in different rays from a texture. The quads would fan out to give the beam look. I started to write some demonstration code to see how it looked, but I'm out of time at my desktop for writing code at the moment.
Answer by JanusMirith · Oct 21, 2014 at 02:17 AM
I would use a projector with a cookie constraining it to a line.
http://docs.unity3d.com/Manual/class-Projector.html
A light with soft shadows would do a good job to.
As for the in air glow perhaps you should try and use a asset like http://www.youtube.com/watch?v=bxTa6oCV6LQ
Thanks, I'll give the projector a shot today. The only issue I'm seeing is that a lot of my environment objects share textures, so if the projector is mapping the texture directly to UV it's going to make for some uglyness. We'll see..
You may want to add a few fanning raycasts that drive line renderers, that way the in air beams would also be occluded by the props in the scene.
Answer by Kiwasi · Oct 21, 2014 at 06:46 PM
A particle effect with world collision enabled and a submitter on collision?
Now that I write that down it could be rather expensive.
Yeah I had that thought as well. I think I could make it work, but for mobile it's probably too much. How would I cast multiple rays in an arcing pattern? IE - ray1 = 0deg, ray2 = 10deg, etc?
Your answer
Follow this Question
Related Questions
How to draw beams? 2 Answers
Character lasergun? 1 Answer
Beam Weapon 1 Answer
Ray Gun / Laser Beam 3 Answers
Laser using line renderer 1 Answer