Microsoft offers DirectX Raytracing or DXR in short with Windows 11/10. With the first generation of hardware, gamers can use Raytracing to build shadows, light, and effects around it in real time. In this post, we are looking at DirectX Raytracing in Windows 11/10 and what it means for Gaming.
What is Raytracing?
In simple words, raytracing means calculating how light would fall on objects, and how it looks after the light is reflected from that object and the effect of lights that fall on some other object. This helps developers to create a better visualization of their characters and scenarios.
That said, its nothing new, and it’s not something that has been created by Microsoft either. Developers had been using this from CGI times, and it involved pre-calculating the brightness of virtual objects before shipping their games. So there was no realtime Raytracing until now.
DirectX Raytracing in Windows 11/10
There are two parts of Raytracing. It needs support from both Hardware and Software. Starting with the Windows 10 v1809 update, DirectX Raytracing will work out-of-box on supported hardware. This means you will need to change your graphics card which supports native raytracing.
Microsoft has made sure that DirectX Raytracing API is built such that it works across hardware from all vendors. The best part of all this is that Raytracing is now real-time. Developers do not need to perform any precalculation as Game developers now have access to both the OS and hardware to support real-time raytracing in games.
DirectX Raytracing works with Existing Engines
Till date, the industry had been using traditional rasterization to achieve more realistic scenes in games. It lacked reflections, shadows, and ambient occlusion. All these changes with DirectX Raytracing with API developers can use alongside rasterization-based game pipelines integrate DirectX Raytracing support into their existing engines. This means there is no need to rebuild the engines at all.
Microsoft has also shared that several studios have partnered with NVIDIA, who created RTX technology to make DirectX Raytracing run as efficiently as possible on their hardware. Here are some sample images from games like Battlefield V, Shadow of the Tomb Raider, and Metro Exodus.
As of now, developers are going to build games using both rasterization and raytracing. The later is going to be majorly used to calculate the shadows or reflections, while most of the content is generated with the former tech.
Directx 12 / DirectX Raytracing API
The Redmon giant has also made sure that DirectX Raytracing is future proof, and well aligned with the future evolution of GPUs: DXR workloads will fit naturally into the GPU pipelines of tomorrow.
In addition to hardware, recently announced public API, DirectML will allow game developers to integrate inferencing into their games with a low-level API. On higher-level:
- Acceleration structure: Object that represents a full 3D environment.
- DispatchRays: It is the starting point for tracing rays into the scene.
- A set of new HLSL shader types including ray-generation, closest-hit, any-hit, and miss shaders.
- Raytracing pipeline state
That said, it doesn’t introduce any new engine but works on any of the DirectX 12 engines.
Microsoft is betting big on DirectX Raytracing
As the gaming industry progressed to higher resolution and the human eye looking for more realistic views, Microsoft expects that even small glitches can be resolved. A small deviation from the real world can be caught by the human eye because it doesn’t feel right. DirectX Raytracing will help developers to blur the line between the real and the fake.
What do you think of DirectX Raytracing? Do you think we will see better games in the coming years? Let us know in the comments.