Demo Scene - Scanner

 

Collide with Environment without a Line Trace

 

Combining a SceneCapture2D Actor with a Point Cloud can create a scan like effect. Set the SceneCapture2D to render the SceneDepth and pass the RenderTarget as a reference to the PCA Data Asset of the Point Cloud. Set the Point Cloud up to spawn a 2D grid of Points, which will be moved along the X-axis according to their corresponding SceneDepth. This will create a Point Cloud that matches the environment of the scene. Note that the PointCloudActor is a child of the SceneCaptrue2D Actor in the scene, to be able to follow its movement and orientation.

Even so the Point Cloud is now moving with the SceneCapture2D Actor, it is not difficult to calculate an offset to place it somewhere else in the scene. In Game use the T key to toggle the offset on/off. Because all this is done in a Material it is easy to apply noise or any kind of effect on the Points.