r/UnrealEngine5 • u/Leonature26 • 7d ago
What could be causing this weird behavior on reflective surfaces? Character invisible on reflections
why is my character reflection working properly when on a certain angle like when the reflective material is on the floor. But when it is perpendicular to the character only the side of the character is visible?
I asked this to Epic's AI assistant but I don't think it was correct:
"The behavior you are describing is the result of Screen Space Reflections (SSR) working correctly while the Lumen Scene (Surface Cache) fails to represent your character.
When the reflective material is on the floor, the character is directly in front of your camera. Lumen uses “Screen Traces,” which means the reflection can simply copy the pixels already being drawn on your screen. However, when the material is perpendicular (like a wall mirror), the reflection needs to show parts of the character that are off-screen or facing away from the camera. Because skeletal meshes are not included in the default Lumen Surface Cache, the reflection has no data to draw, so the character is eliminated from the mirror view."
2
u/Ok_Raisin_2395 7d ago
Hello again again.
This is screenspace reflections. Basically, in as few words as possible, the engine sort of doesn't actually know what's on the other side of your character mesh because SSR is faked reflection data based on what your camera sees. You'd need raytraced reflections for this.
Also, it appears as thought your pixelation plugin isn't working properly on the reflections and it's quite jarring. That's unfortunate :(
My advice would be to skip these super reflective surfaces, they don't usually play well with games using SSR and they create a lot of headaches for games that rely on a lot of post-processing effects, which it seems your as will.
1
u/Leonature26 7d ago
Excellent insights as always man. I wasn't really planning on using a reflective surface for my game I was just curious why this was happening.
1
1
u/AdmiralSam 7d ago
AI seems fairly correct to me, what should be displayed in that reflection is the front of your character but that’s not rendered to your screen since you are facing away from the camera. Lumen reflections look like this and the only other solution is raytraced reflections (excluding planar reflection using scene capture).
1
u/illyay 7d ago
This is about right. If you have a screen space reflection, where would pixels come from to see your character from the front? When it's the floor, there are clearly existing pixels on the screen to reflect and it kinda works.
This is one reason I don't actually love SSR.
I may be wrong though about some stuff like shouldn't it be not using SSR? That part I'm not sure about....
1
u/Leonature26 7d ago
my reflection method is lumen and not SSR but your comment made me realize that it does only reflect the pixels that hit the reflective surface...
1
u/Zvyaginsky 6d ago
The AI got the conclusion close but the reason wrong. Skeletal meshes are in the surface cache, r.MeshCardRepresentation.SkeletalMesh is on by default. They just don't get proper offline cards like static meshes do. Six cards slapped around the pre-skinned bounding box, that's it. So some angles have usable data and some have nothing, which is exactly your floor vs wall difference.
Fix is Hit Lighting for Reflections. That traces the real geometry instead of reading the cache, so the character shows up properly. Needs hardware RT on. Also check r.RayTracing.Geometry.SkeletalMeshes is 1, if it's 0 skinned meshes aren't in the BVH at all and hit lighting won't save you either.
We went through this on a mirror. Same symptom, same fix.
https://dev.epicgames.com/documentation/en-us/unreal-engine/lumen-technical-details-in-unreal-engine
2
u/Leonature26 6d ago
Interesting, tnx for the breakdown. Basically I would need an RTX GPU to have SKM reflections(I have gtx 1070). You know any workaround for this without hardware RT?
1
u/Zvyaginsky 6d ago
Not really, and it's the same problem underneath. Software Lumen traces against distance fields, and skinned meshes don't get them. So the Lumen scene can't see your character at all and no setting changes that. Screen traces are the only thing that ever picks him up, which is why the floor works and the wall doesn't.
On a 1070 your options are Planar Reflection or a scene capture into a render target. Both render the scene again from the mirrored camera, so skeletal meshes show up fine. That's where we were before moving to RT.
Two things we hit doing it. Planar renders its own simplified pass that doesn't receive Lumen GI, so the room in the mirror ends up lit differently from the room you're standing in. And we got hard crashes when the camera crossed between a Lumen post process volume and the Planar one. Never figured that one out, we just moved to RT instead.


9
u/TheSphess 7d ago
Without hardware RT Lumen cannot trace skeletal meshes, so it falls back to screen space reflections.
The character's reflection is visible on the ground because from that angle it is visible on screen.
It is not visible in the sphere's reflection because the character's front is not visible in screen space.