Download

Some questions on reflections and their behavior.

Hello guys,

New to the engine here, so please bear with me.

I’ve been going over some reflection options in Unreal (specially for dynamic moving objects), and I’m trying to understand their behavior and limitations, and if possible some workarounds.

From what I understand so far is that we have a few options in Unreal to create reflections:

**Screen space reflections: **

A post process effect with some major drawback such as, it can only render what it sees, in other words if I tilt the camera down I will not get anything reflecting on most parts of the ground from the environment. but it produces best compromise of dynamic reflections and look, for general purpose scenes.
**
Spherical or cubic static reflection captures:**

Basically a statically captured scene either 360 degrees or cubic is projected as reflection onto the given environment within a given radius. may work well to help out some areas, but it creates inaccurate distorted images of objects in close proximity of others when viewed on flat surfaces among other things.

Finally a scene capture dynamic method: which is exactly the same as the spherical capture only difference is that it captures for every frame so if we have moving objects this would show them, understandably the doc mentions its expensive to use.

In a specific situation such as having reflections on a still body of water. and suppose a tree or a large rock in the middle, how would one approach on faking the reflections to be very accurately “mirrored” onto the surface of this object/material.
By mirrored I don’t mean placing a simple camera with a given FOV and projecting that back onto the surface, for that would never really work right it for such large surfaces, but rather having some kind of an accurate dynamic or semi dynamic reflections for this surface for a given radius or selected objects. for instance having the sky as fake static reflection along with the rocks but reflect moving objects dynamically such as characters or moving trees in the wind, also accurately, for instance you would clearly be able to see in the reflection the Bark of the tree with its correct placement and perspective moving upwards and see the leaves reflect correctly. Perhaps this is not possible for the time being, however I would like to know if there is any functional method out there in Unreal that could help us achieve proper dynamic mirror like reflections.

2850817-abstract-of-an-oak-tree-in-full-leaf-in-summer-standing-alone-and-surrounded-by-flooding.jpg
16422902-swan-on-blue-lake-water-in-sunny-day-swans-on-pond-nature-series.jpg

While I am wondering about the above question, I have another:

The image test below shows a strange behavior with screen space reflections, it seems that the closer i bring this cubic wall to the objects such as the trees the “better” the reflections are represented, is this a limitation with the reflection method? why are the reflections not displaying correctly without having a very close wall?

Thank you very much.

Screenshot_ref.jpg

The main limitation of Screen space reflections is indicated by the name: they are in screen space and cannot reflect anything not currently on the screen.

This explains why your close wall image works better, there is little difference between the scene and it’s reflection. The further away the wall is, the bigger the offset between the trees and the wall in the reflection, which results in the SSR algorithm missing information to accurately reconstruct the reflection.

This is a fundamental limitation of SSR. In general you get the best results when you combine multiple reflection techniques and use each of them for their own strengths. One that you did not mention, but which would help in this scene is the skylight. It not only provides indirect lighting from the sky, it also provides a special case environment capture of the background of your scene. In the open environment of your example scene it should be able to nicely fill in most of the places SSR misses.

Another thing you can do is raise the SSR quality, while there is no way it can magically know what isn’t visible in screen space, raising the quality settings does help with the overall appearance of the SSR. The quality can be raised quite a bit with a post process volume, although I believe there are even higher (and more expensive) quality options only available with console commands or ini modifications. I never really needed to go beyond what can be set in the post process volume, but you can probably find more info on that somewhere in the docs or on in another thread if you think it might help your scene.

In the end an highly irregular object like a tree over a smooth plane of water is basically the worst case scenario for the reflection systems in UE4. It is probably best to do some standard game trickery and add some waves or rocks to logically perturb the water surface, which would allow you to get away with far easier to fake messy reflections.

Hopefully UE4 will get better planner reflections, it’s been requested over and over, and would really help improve situations like this.

Thank you guys for your insight into this,

I have the SSR quality set to 100 always. and true about skylight, but background reflections such as sky or distant mountains are easier to fake, my concern was movable objects acting as hero elements on screen inside certain environments, in this case outdoor still water reflections.

I Thought SSR kind of worked like Z-depth and would be able to distinguish the objects at certain Depth position and fake the reflections accordingly at that location, it was a little puzzling as to why the background would mess up that information for the foreground objects and displace the position of reflections of these objects so much.

Unfortunately objects such as trees to be reflected was specially the kind of objects i needed to reflect properly, I also guessed that probably like you said they are the worst case scenario for this. So from what i gather is that there is no real way to do this and we have to go back to the drawing board to move around it.

It would have been great to have some kind of a fake but accurate planar reflection capture which can grab certain objects movable or static with certain channels assigned (to save performance) similar to what they are doing to lights in 4.11 only this time for reflections, but the reflections have to be accurately projected onto the surface, I hope they would come up with a nice solution to this, it would help greatly.

Meanwhile if any of the community members wish to share some tricks, it would help us all greatly.

Thanks again!

Epic created reflection billboards for the bullet train VR demo, that could work, they talked about it in the live stream for it.

I just watched the VR live stream, those reflection billboards are worth checking out, perhaps they can be of some help, any tutorials or sample files out there for this?

I think by “bullet train” ZacD meant “bullet time” - there’s a demo of it on the Learn tab. Downloading it now to see if it has the billboards and maybe I’ll migrate them over. I have a room with a mirror on the wall but even with the Screen Space Reflections setting at 100, it can’t see the opposite wall so the whole thing is black. I even tried setting it to a material from the reflections demo and giving the roughness a value of zero- the closest i got was a very fuzzy, murky black reflection of the opposite wall. When a character walks in front- right up to it- it’s still really murky so :\ idk. hopefully these billboards will help…

I dug around in it but couldn’t find anything. Just some scene capture cubes. Know what they were called?

Here’s what I was talking about with the fake reflections https://youtu.be/PG2fHLdzRIs?t=1592 (27min if the link doesn’t go to the right time)

Guys anyone know of a way to crop a custom ‘viewport’ to show only parts of camera’s capture frame and display that as fullscreen ? (the concept of viewports was common in good old programing languages)

I know this will degrade quality if doable, but that way you can ‘zoom in’ so to speak to parts of the screen while keeping the screen space reflection (whose source is now outside the ‘viewport’ but still inside the camera render frame that isnt fully displayed)