What is DirectX Raytracing / DXR?
DirectX Raytracing, or DXR, is a Microsoft DirectX 12 technology that lets games and graphics applications trace simulated light rays in real time to create more realistic reflections, shadows, lighting, and global illumination.
In simple terms, DXR helps a GPU calculate how light behaves in a 3D scene. Instead of only estimating light with traditional rasterization tricks, DXR allows developers to model how rays bounce, reflect, and interact with objects.
DXR exists to bring movie-like ray tracing effects into real-time applications such as PC games, game engines, visualization tools, and graphics demos. Microsoft introduced DirectX Raytracing as a DirectX 12 feature in 2018 to bridge traditional game rendering and more physically accurate 3D lighting.
Key Takeaways
- DXR stands for DirectX Raytracing.
- It is part of Microsoft’s DirectX 12 graphics ecosystem.
- DXR enables real-time ray tracing effects in supported games and applications.
- It improves realism in reflections, shadows, lighting, ambient occlusion, and global illumination.
- DXR requires compatible hardware, drivers, Windows support, and software implementation.
- It usually works alongside rasterization rather than replacing it completely.
History and Evolution
DirectX Raytracing first became widely known in 2018 as Microsoft’s ray tracing extension for DirectX 12. It arrived as game developers and GPU makers began pushing real-time ray tracing beyond offline movie rendering.
DXR later became a key feature of DirectX 12 Ultimate, alongside technologies such as mesh shaders, variable rate shading, and sampler feedback. Microsoft described DXR 1.1 as part of DirectX 12 Ultimate’s graphics feature set.
In 2025, Microsoft announced DXR 1.2 with newer performance-focused features such as opacity micromaps and shader execution reordering, designed to make ray tracing more efficient in complex scenes.
Why DirectX Raytracing Exists
Traditional rasterization is very fast, but many lighting effects are approximations. Reflections may miss off-screen objects, shadows can look inaccurate, and indirect lighting often needs baked or precomputed data.
DXR exists to solve these visual limitations by allowing games to trace rays through a 3D scene. This helps produce lighting behavior that is closer to real physics, especially in scenes with mirrors, glass, metal, water, smoke, and dynamic lights.
How DirectX Raytracing Works
DXR works through the Direct3D 12 ray tracing pipeline. A game engine builds acceleration structures, which are optimized data structures that help the GPU quickly test where rays hit objects.
Then the GPU runs ray tracing shaders to determine what happens when a ray is generated, misses an object, or hits a surface. Microsoft’s Direct3D 12 ray tracing documentation lists dedicated ray tracing APIs and shader stages used for this pipeline.
In most games, DXR is used selectively. A scene may still be rendered mainly with rasterization, while DXR handles specific effects such as ray-traced reflections or ray-traced shadows.
Key Characteristics
- Hardware acceleration: Modern GPUs use dedicated ray tracing hardware or optimized compute resources.
- Hybrid rendering: DXR usually combines ray tracing with rasterization.
- Real-time focus: It is designed for interactive graphics, not only offline rendering.
- Developer-controlled: Games must specifically implement DXR effects.
- Performance-sensitive: Higher ray counts and quality settings increase GPU workload.
Compatibility and Requirements
DXR works with DirectX 12-compatible systems that support the required ray tracing features. Microsoft’s Direct3D 12 ray tracing samples list a GPU and driver with DirectX 12 Ultimate support as a requirement.
Compatibility generally depends on:
- Windows version and DirectX 12 support
- GPU ray tracing capability
- Updated graphics drivers
- Game or application support
- Graphics settings enabled by the user
Advantages
DXR can make game worlds look more believable by improving how light behaves. It is especially useful for accurate reflections, contact shadows, realistic indoor lighting, and scenes with many dynamic light sources.
It also gives developers a standardized DirectX-based path for adding ray tracing to Windows games and engines.
Limitations
DXR can reduce frame rates because ray tracing is computationally expensive. Performance depends heavily on GPU architecture, resolution, ray tracing quality, upscaling technology, and game optimization.
Not every game supports DXR, and not every ray-traced effect looks equally noticeable. In some titles, the visual difference may be subtle compared with the performance cost.
DirectX Raytracing vs Traditional Rasterization
| Feature | DirectX Raytracing / DXR | Traditional Rasterization |
|---|---|---|
| Main purpose | Simulates light rays for realism | Converts 3D geometry into pixels quickly |
| Strength | Reflections, shadows, global illumination | High frame rates and efficiency |
| Accuracy | More physically realistic | Often uses approximations |
| Performance cost | Higher | Lower |
| Common use | Premium lighting effects | Core real-time game rendering |
Common Misconceptions
Is DXR the same as ray tracing?
DXR is not ray tracing itself. Ray tracing is the rendering technique; DXR is Microsoft’s DirectX 12 API technology that allows developers to implement ray tracing in supported Windows games and applications.
Does DXR replace rasterization?
DXR usually does not replace rasterization. Most modern games use hybrid rendering, where rasterization handles the main image and DXR adds selected lighting, shadow, or reflection effects.
Does every DirectX 12 game support DXR?
No. A game can use DirectX 12 without using DirectX Raytracing. DXR must be specifically implemented by the developer and supported by the user’s hardware and drivers.
Real-World Examples
DXR is commonly used in modern PC games for ray-traced reflections on glass, puddles, and polished floors. It is also used for realistic shadows, improved ambient occlusion, ray-traced global illumination, and path-traced graphics modes in demanding titles.
Related Technology Terms
- Ray Tracing: A rendering method that simulates light rays to create realistic lighting and reflections.
- Rasterization: The traditional real-time rendering method used to draw 3D scenes quickly.
- DirectX 12: Microsoft’s low-level graphics API used by many Windows games.
- Path Tracing: A more advanced ray tracing method that simulates many light paths for high realism.
- DLSS / FSR / XeSS: Upscaling technologies often used to improve performance when ray tracing is enabled.