Download

Raytracing was merged into Dev-Rendering!

I was actually able to run it!

Trick was -dx12 and -raytracing . On a rtx gpu with latest drivers and latest windows version (1809)

All tested in a 2080, in editor fullscreen 1080p, on the Realistic Rendering apartment.

Current state of stuff:

  • No denoising whatsoever, or at least i couldnt get it to run.
  • Current noise formulas make noise even worse than it should be, with tiling artifacts.
  • Raytracing AO gets calculated, but then gets overriden by something else and never gets displayed. Cost is about 1.1 miliseconds per raytracing sample. If denoising actually works on such a bad 1 sample image, this could be competitive with SSAO.
  • The entire “backend” of raytracing shaders and acceleration structures actually works fine.
  • Reflections work super well, but they are SUPER expensive. Perfect mirrors are fun to look at. Costs 15 miliseconds with all features enabled. Trying to recalculate light on the hits + raycasting to that light for shadows is expensive. They could be more useful in static light scenes.
  • Directional lights, pointlights, and rect-lights all have direct rayshadow support, and they all look great. If you dont you get pixel perfect shadows that look like Stencil Shadows. Actually not expensive to run, somehwere beetween 0.1 and 0.6 miliseconds per light, at 1 sample per pixel, depending on how much of the screen is affected by the light, which is great (better sun shadows that cascade shadows?)
  • Spotlights dont work, at all. Not even direct light. EDIT: Spotlights got fixed a couple commits after what i downloaded.
  • Has a pathtracer, but its light is super weird and it doesnt converge.
  • Crashed GPU driver several times (but i was debugging with Nsight)

In general, this is extremelly early. Really fun to see where the tech is going, i can see the potential. Enabling raytracing is automatic and you dont need to modify the scenes to use the features. Ill be tinkering with it again once it starts getting denoising features.

My biggest interest is RT shadows and RT AO, both of them i see them happening, and they are essentially a “toggle” to enable them. At 2-3 miliseconds for both, they are well within usable territory for 60 fps gaming. Reflection… i dont see that happening at good speed without mayor engineering, and on games that could have it not be absurd. Having to recalculate the entire PBR material + light + extra shadow rays where the reflection hits is just never going to be fast.

Bonus picture:
I cranked the settings really high so i get a decent image even without the denoising, just through the TAA.
The image shows area light (the blue light), a pointlight (orange) with pixel perfect shadows, and reflections on the chrome sculptures, including reflecting an ofscreen shining cube.

Thanks for posting that pic vblanco! Look forward to seeing the braver souls dig into this at such an early stage. Can’t wait till this is enabled in a standard release.

Will do my tests also and will provide a video probably this weekend, also on a RTX 2080 non ti

So there is not yet support for GI ? I guess it’s coming anyway, it’s bascially extension of AO and should super cheap, since it only transfer color information.

There is some surfel related code around the sources. But there is no GI i can find right now. Surfel GI 2, Raytracing edition would be a great thing. I think they showed it on the GDC demos

I made a video about the raytraced shadows, wich are the thing that looks the best right now. This is just me tinkering a bit with the area shadows and pixel-perfect shadows from pointlights.
Rendered at 30 samples per pixel + TAA, which can be useful to “preview” how could it look when it has proper denoising.

Seeing these shadows realtime inside UE Editor left me in shock O.o

Dxr cant work non-Rtx card ?

Hello, I downloaded the latest branch to build, then turned on two options in the project settings, and added - dx12 and - raytracing command parameters to Editor’s startup shortcut, but did it still seem to have no effect after entering the engine? But shader compilation does add a lot, May I ask you the steps you used?

I followed the steps without any options to adjust, and the console parameters did not seem to work. I’m sure I’m using 2080TI + WIN10 1809 and I’ve run Microsoft’s DXR tests before, but I don’t seem to be able to enable them in the engine.
And I also confirmed that the engine was running on DX12, but no light or console commands were visible. Ray tracing effect.

This is the log output in the console.

LogInit: Command Line: -dx12 -raytracing F:\DXR_UE\PhotoRendern\PhotoRendern\PhotoRendern.uproject
LogConfig: Setting CVar [r.RayTracing:1]]
LogD3D12RHI: D3D12 ray tracing enabled.
LogD3D12RHI: Ray tracing resource residency tracking is not implemented. Disabling D3D12 residency management.
LogUObjectArray: 40164 objects as part of root set at end of initial load.
LogUObjectArray: CloseDisregardForGC: 0/0 objects in disregard for GC pool
Cmd: r.RayTracing ?
HELP for ‘r.RayTracing’(ReadOnly):
0 to disable ray tracing.
r.RayTracing = “1” LastSetBy: ProjectSetting

Is it really exclusive to the RTX card, even when the binary is released? I was hoping to utilize it in a film project. The performance in my case isn’t entirely necessary.

Just because of those shadows DXR is worth it ;o.

And they seem to be cheaper than shadow maps.

Thanks vblanco for sharing your early experiments with us. Those shadows look fantastic!

Those shadows

Hello, I downloaded the latest branch to build, then turned on two options in the project settings, and added - dx12 and - raytracing command parameters to Editor’s startup shortcut, but did it still seem to have no effect after entering the engine? But shader compilation does add a lot, May I ask you the steps you used?

I followed the steps without any options to adjust, and the console parameters did not seem to work. I’m sure I’m using 2080TI + WIN10 1809 and I’ve run Microsoft’s DXR tests before, but I don’t seem to be able to enable them in the engine.
And I also confirmed that the engine was running on DX12, but no light or console commands were visible. Ray tracing effect.

This is the log output in the console.

LogInit: Command Line: -dx12 -raytracing F:\DXR_UE\PhotoRendern\PhotoRendern\PhotoRendern.uproject
LogConfig: Setting CVar [r.RayTracing:1]]
LogD3D12RHI: D3D12 ray tracing enabled.
LogD3D12RHI: Ray tracing resource residency tracking is not implemented. Disabling D3D12 residency management.
LogUObjectArray: 40164 objects as part of root set at end of initial load.
LogUObjectArray: CloseDisregardForGC: 0/0 objects in disregard for GC pool
Cmd: r.RayTracing ?
HELP for ‘r.RayTracing’(ReadOnly):
0 to disable ray tracing.
r.RayTracing = “1” LastSetBy: ProjectSetting

Based on the logs, ray tracing was indeed enabled. Are you saying that there are no ray tracing view modes available in the editor for you? From here I would suggest that running the engine via a debugger and stepping through the code to figure out why RT features are not getting used. First place to start could be LightRendering.cpp. Search for ShouldRenderRayTracingStaticOrStationaryRectLight and step through the code nearby. Perhaps the reason for unavailability of RT features would become obvious then.
Unfortunately, I don’t think I can provide any further support at this point.

You should use DevRendering branch, not master maybe. DevRendering is the one i used, added -dx12 and -raytracing to shortcut, then turned on skincash and raytracing in projects settings.

Okay, thank you for your reply. I downloaded the latest rendering branch. Ray tracing seems to be working properly. I’m testing related functions. Shadow performance is very good, reflection consumption is very high, but noise reduction seems not ready yet? Shadows and reflections look really good. I seem to have seen the biggest rendering upgrade of Unreal in 4.22, and the consumption of new shadows is very exciting. It seems that we can say goodbye to the bad CSM shadows! Thank you for your work to show us such beautiful real-time images!

Can raytraced shadows and AO be “slowed down” enough to work with VR?

There’s a few generic GPU implementations of voxel traced GI under development for Unity, and those demos show all shadows moving in “slow motion” compared to the objects and lights in order to not stress the GPU to pieces. Can that be done here as well to make it smooth in VR?

Does polygon count impact dxr shadows or is it pretty much a flat bump in render time per light or scene size?

I’ve just done some tests. Ray tracing shadows really consume very little, even in some cases, less than CSM shadows. The influence of polygons has not been tested yet, but in theory, ray tracing shadows should have little impact on the change of scene polygons.

Hi people!

Is RTX shadows means we will not need to rely on lightmaps for direct shadows? I hate lightmaps :slight_smile:

Maybe we can expect some improvement on volumetric fog with RTX?

I´ve see some videos on NVIDIA´s Youtube channel and this tech is awesome!