Lumen GI and Reflections feedback thread

Ray tracing is not good enough performance wise. It has a extremely bad visual to performance ratio when compared with alternatives.

I’m not talking about screen space reflections , I’m talking about a better fallback than cubemaps. Skylight with SDF specular occlusion would just have outlines rather than Lumen reflections having issues like black objects and voxel imprinted textures issues.

Skylight with SDF specular occlusion would act as a major replacement for cubemap fallback in large worlds and could(need Daniel’s opinion) cut out computations lumen reflections have while have a more subtle photorealism approach. I Imagine tracing SDF is not the most expensive part of lumen reflections but Daniel would know more on that.

cubemaps are the proper fallback for relfections. it’s real environment textures that reflect. a skylight (directional is sharp, ambient is soft) even with sdfs blocking it will give you just a basic gloss or just ambient mud.


on the brink of asking engine coders. what would be the proper way to add dbuffer decals to glass refraction and reflection? translucent z prepass? render the decals into thin air. then composite? a nice challenge. hmm

basic gloss or just ambient mud.

If combined with a method like stochastic SSR, should work in the majority of basic and common gameplay while keeping a strong sense of photorealism.

Most of time, (its gets pretty raining where I live) outside puddles are usually the color of the sky and RL materials are just darkened with “basic gloss”. IRL, you have to try a lot harder in games to break this design. The visual to performance ratio is much better than current options in the games we have now.

where’s the reflection in that video? the puddles only reflect the scene and lights in the emissive pass, but not the sky. it’s black sky. huh?

That’s actually exactly what the old DFAO implementation did- it handled sky occlusion as well as specular occlusion via bent normals, although I don’t think it had the same ray tradeoff capabilities as lumen does now.

That said, if you’re using lumen GI, disabling dedicated reflection rays but keeping SSR and the rough lumen probes gives you good results for basically free.

I feel like Teardown is an excellent game to demonstrate what that looks like: It has full sky occlusion for both diffuse and specular; in outdoors areas it can be enough for a decent look, but it basically means no reflections at all in many scenarios.

My immediate thought was to use the “Static Mesh Decal Function” which is a material meant to be used on a translucent box that basically does depth reprojection to create UVs for decals. But it appears that raytraced translucency is having issues with the function because it can’t properly sample the scene depth. Plugging it into a scalar debug node output a flat value of 1,000,000… but its just black. With that node broken, I don’t see any way of using depth reprojection to create a decal.

If it did work, then you could use it in place of dbuffer decals - or what I’d probably do is use the dbuffer in the main pass and make the decal function only visible in RT (since dbuffer has more features).

Annoyingly RT translucency is all or nothing. AFAIK so you can’t set the decal function box to be raster while glass is RT to get around the bug either.

Not sure if there’s a good reason why you can’t mix raster and RT translucency in the same PPV but I really think it should be allowed. I’d like to be able to pick and choose… But that aside, the bigger issue is that the scene texture/depth nodes appear broken in RT translucency.

Until one of those two things are fixed, the only way I can see it working is if you had a conforming mesh with an opaque masked material that has the decal texture on it and lined it up closely to the real decal, kind of like this image from the mesh decal documentation:

It could once again be visible in RT only so you can get better blending and whatnot with the dbuffer in the main pass.

1 Like

yeh… you can’t just render something in the z pre pass and hide it in the base pass. i’m aware of that. this would also create discontinuities if you’d have a decal on a surface behind the glass. either way i need full dbuffer access in the t pass. at this point the gbuffer should be free to use. my goal is to get the decal normal into the glass. maybe some shiny blood splatter on it. lil bit of rated r action. tlou style. hmm

You can write the glass to the custom stencil, then place/spawn a flat transparent plane with the blood textures on it. Can be forward shaded so you get roughness and normals. Use the custom stencil to hide the blood splatter anywhere that isn’t the glass, and place/spawn a dbuffer decal in the same spot to draw the blood on any opaque surfaces if needed.
This will handle basically every case that the glass is a flat plane - which is probably most cases overall - and the masking will help prevent floating textures when the decal might extend beyond the glass (like with a broken window).

This isn’t the place to get into the depths of the dbuffer so I’ll just leave it at that.

yeah… i think ima ditch the idea. taa/tsr is not having it, either way. it can’t handle the motion of the details. dunno if it’s the reflection or “refraction” (not even enabled there).

that’s unfortunate. gotta be cheap glass. no shatter fx. hmm

Enable draw to depth and velocity in the material. It’s because the motion vectors are from whatever is behind the glass, causing TAA to over compensate and wig out.

1 Like

okay. that works. cool. i changed the shatter material approach anyway. and it still breaks, cause actual refraction is screenspace. this works for fp but not tp games.

this is tough to fix. i’m aware of that.

1 Like

That’s actually exactly what the old DFAO implementation did-

Here is a small video showing the effect via just removing all lumen cards. It also shows DFAO failing. SSR will not hold up in complex scenes and cubmaps take to long for giant worlds. Ofc still unperformant due to all other Lumen logic running but the look it definitely holds up with reference photos (real life rain). I just wonder what percentage of Lumen’s cost is tracing SDFs to this level.

If relatively small, it’s a win and I wonder how ROMA could speed it up since it’s faster to trace from(but also requires jittered rebuild per-frame to avoid voxel like aliasing).

what’s wrong with raytracing? it works playable on a ps5 level gpu (my 3060 is a lil lower in raster output actually). fps players don’t care about fx. in “cinematic” mode you end up above 30 (unless you torture the hardware). with all the goods. plain digital movie framerate. moblur smears the lil frame hitches. it’s decent performance wise for what actually is doing. and looks great in my lil testlab. hmmhmm :slight_smile:

captured in editor ofc. dunno how the package performs, rn.

1 Like

Started playing with Lumen today and I am unsure what I am doing wrong. (Unreal 5.3.2)

  • I created a basic oven inside blender and textured it inside substance painter before exporting the textures to unreal
  • I haven’t messed with the project settings apart from turning on hardware raytracing, and a few other tweaks which are meant to help
  • The oven looks correct in the mesh preview and it’s using lumen for reflections and lighting as far as I can tell
  • Placing the oven in game however looks awful (Default scene, no changes at all). The glass reflections looks good no matter the distance, but the chrome parts look hideous if you are more than 3 ft away.
  • All scalability options are on high, I have tried cinematic but it tanks my FPS with no visual difference
  • If I switch reflections from Lumen to SSR or Realtime Ray Tracing then it looks perfect
  • Nanite on/off has no effect
  • Using TSR with 4x MSAA, turning these off/changing them doesn’t help
  • Played around with the PostProcessVolume settings, even cranking them up to silly values doesn’t help

Mesh preview (Good reflections, using lumen for both GI and reflections):

In game object (Blurry grey/blue metal, using lumen for both GI and reflections):

  • I have attatched a video showing a close up shot, then pulling out. The reflections view correctly shows what I expect, but in the lit view the chrome turns a dull blue past a few feet.

I am also unsure why Lumen is so much worse than plain SSR, even close up (SSR is missing the reflections close up, but at least it looks like metal)

Close up lumen:

Close up SSR:

Close up raytracing:

Project settings:

Material settings: (I tried switching both metallic and roughness to constants with the values 1 and 0, didn’t help. The OcclusionRoughnessMetallic map has sRGB turned off, switching between Default compression setting and “masks (no sRGB)” has no effect.)

I also created a new scene using a HDRIBackdrop, downgraded to 5.2.1, etc. Nothing has made lumen reflections look good so far. Any help would be appreciated!

that’s too much details, imho. do you really need perfect reflections on those chrome knobs? in a game setting? or are you advertising chrome knobs. hmm

Are the handles and knobs supposed to be chrome or rough/brushed metal?
The legacy raytraced image is showing pin sharp reflections (roughness of 0) while the Lumen image appears to have a higher - but still low - roughness (maybe like 0.1). If both images are using the same roughness map, there should not be a noticeable difference between them.

Here are two images of metals with a roughness of 0.15, one has legacy RT on, the other has Lumen on… can you tell which is which?


Any raytracing on rough metallic surfaces is going to look worse that smooth, lumen or not. Here is an image of a 0 roughness metal with Lumen, looking sufficiently metallic.


Once you start to increase the roughness of raytraced metal, things get a little unstable and fuzzy - especially in motion.

Your project settings look fine. That’s about all I can say without actually inspecting the assets itself - Lumen should generally look exactly like the legacy RT, except with proper GI contribution.

Oh, and the 1st image was Lumen, 2nd was RT.

that’s too much details, imho. do you really need perfect reflections on those chrome knobs? in a game setting? or are you advertising chrome knobs. hmm

Unfortunately, kinda. This is also ignoring the point it’s not functioning as I see it working in all the demos and tutorials. I have followed multiple youtube tutorials to the T, and theirs looks like metal whereas mine does not.

Are the handles and knobs supposed to be chrome or rough/brushed metal?

They are meant to be chrome

The legacy raytraced image is showing pin sharp reflections (roughness of 0) while the Lumen image appears to have a higher - but still low - roughness (maybe like 0.1)

In the screenshots I changed the material constants so the metallic was 1 and the roughness was 0. I also disconnected the A̶l̶b̶e̶d̶o̶ (EDIT: Meant to say ambient occlusion) and normal. This means it was just the colour, and two constants. The only thing changed between screenshots was the reflection type (Lumen>Raytracing) and they look completely different, hence the post.

Any raytracing on rough metallic surfaces is going to look worse that smooth, lumen or not. Here is an image of a 0 roughness metal with Lumen, looking sufficiently metallic.

How have you done this? I switched from the oven model to spheres and no matter what I do it’s a fuzzy mess. Even the materials inside the Unreal content demo look terrible on my computer and I don’t know why. I have a RTX 2060 which I think should be able to handle this completely fine?

The material applied to the sphere:

Lumen:

Raytracing:

This is the exact same sphere, same material, only the reflection method changed. This is the best the Lumen sphere looks, the more you pull away the worse it becomes. Lumen reflection settings (I went through like 10 different combinations of values, I couldn’t tell any visual differences apart)
image

I have reinstalled the engine twice, downgraded, etc. Would it be possible for you to send me the project with the metal sphere you have?

Oh, and the 1st image was Lumen, 2nd was RT.

I really wished mine worked like that lmao

EDIT: Also updated graphic drivers to latest with no change

Another photo of the Lumen sphere from further away, can’t even see the cube in it’s surface
image

Raytracing:
image

What is the reflection quality set to? Found in the PPV.

If that is set to something very low (like 0.25) then it will look terrible. Pretty sure it should be 1 by default, but maybe your project is weird.

1 Like

@billyjoetyler

r.Lumen.Reflections.Temporal 0

Also worth noting that the lower the screen percentage is, the worse your reflections will be, especially at a distance. So you should ensure that your screen percentage is set to 80 or higher.

Lumen reflections are temporally upscaled(without TAA) in the reflection channel which is why it’s blurrier and more performant than your RT reference.
r.Lumen.Reflections.DownsampleFactor is put on 2 to save massive perf.

If you put it to 1 or 0, you will get full res reflections. But I imagine your and your customer won’t like the performance you’ll receive.

EDIT:

Another photo of the Lumen sphere from further away, can’t even see the cube in it’s surface

If the cube is small or far away then lumen with cull it to save trace performance.

1 Like