Is there a way to flag only certain objects to render for planar reflections?

We have a PSVR scene with a completely flat (but with a normal map), shiny floor. Screen space reflections have proven too costly, so we’re looking for other ways to reflect objects on the floor. We’re playing around with the Epic Bullet Train VR demo method, and it’s working ok but does have some problems, but as far as I know, the demo source isn’t available to the public yet, and so we’ve had to guess at parts of the implementation. (if the demo source is available, please point me in the right direction!)

Another idea is to use the new planar reflection feature in 4.12. We can’t afford to reflect the entire scene, but fortunately we’d only need to reflect a small handful of objects to convey the shininess of the floor. Is it possible to flag only these small handful of objects to participate in the planar reflection render pass?

Planar reflections do support selective object rendering, by using scene color alpha to track opacity in the reflection pass. Other reflection methods will fill in where no object was rendered into the planar reflection.

In 4.12 the only way to specify what to render into the planar reflection was with the blueprint function ShowOnlyComponent on the planar reflection component. In 4.13 there’s an array in the details panel that’s much easier to setup: ShowOnlyActors.

Using the ShowOnlyComponent node worked well. As you pointed out, it’s tedious to use, particularly because our objects aren’t all in the same level. A checkbox on the actors we want to reflect would be nice. This would allow us to bulk-edit the checkbox property on the objects we want reflected. Though, to be useful, the checkbox would have to default to not be reflected.

Something else that may help with performance is allowing us to specify the LOD of the objects to use in the planar reflection pass. This would be specified on the object’s mesh component, and would allow us to use a lower LOD for the reflections.

Now that we have this working, we’ll check out performance on PSVR. Are planar reflections a full-screen effect, or is the additional cost only the overhead of rendering each reflected object a second time?

A checkbox on the actors we want to reflect would be nice.

So far we have avoided this implementation because there can be multiple planar reflections.

Something else that may help with performance is allowing us to specify the LOD of the objects to use in the planar reflection pass.

For sure. I think we will expose this as a screen size multiplier on the planar reflection. Right now planar reflections do a good job of scaling down scene pixel cost due to the default ScreenPercentage 50 + TemporalAA to stabilize it, but triangle cost is the same as the main scene. LOD controls will be important to scale down triangle cost as well.

Are planar reflections a full-screen effect, or is the additional cost only the overhead of rendering each reflected object a second time?

There are three parts: 1) the capturing of the scene. The cost here entirely depends on what you have setup to render into the planar reflection and what screenpercentage you have set. 2) prefiltering of the planar reflection. The cost depends on the prefilter roughness, and size of your main render targets. 3) Applying to pixels affected. This is done as a full screen quad atm. In the future we’d like to render bounding geometry just like deferred lights / decals.

1 Like