What Is Ray Tracing And What Is It For?

Ever since real-time ray tracing, or RTX, has entered the gaming sphere, it has been used as a secondary term for great graphical quality, memes have even become commonplace showing ‘RTX off’ vs ‘RTX on’ with the on version showing something entirely more beautiful, but it has a very specific meaning. Whilst it is quite a big technical leap that can really push the graphical quality of the game, it isn’t something that just makes everything look nicer.

What Is Ray Tracing?

Ray tracing refers to a computer working out calculations by sending out straight lines from a point, called rays so that it can judge the distances and interactions with other objects. Its most common usage is used in lighting or reflections, but it can also be used for other things such as working out what an AI has visual sight of.

Real-Time Ray Tracing | Unreal Engine Documentation
Unreal Engine – Epic Games

Ray tracing has been around in video games for a long time now, since the earliest days of 3D. So why is it suddenly being talked about so much? The big technological advancement is being able to project them and collect the information in real-time. Previously these were pre-determined at the development stage as they could take hours or days to compute, then that information was saved, for example in lightmaps which save all of the lighting information and apply them as a texture. We’re now reaching the stage where these calculations can be done in real-time.

Why Is Ray Tracing Important

Using the example above, saving lighting information in a lightmap means that once the lighting is saved, it cannot be changed, this means the object cannot be moved without looking broken. We have been using alternatives to ray tracing for a while that allows the lighting to be real-time, but its accuracy isn’t great. Real-time ray tracing makes these calculations very accurate at all times.

Real-time ray tracing in Unreal Engine: Part 1 - the evolution - Unreal  Engine
Unreal Engine – Epic Games

One of the biggest areas of improvement that can be seen is in reflections. In the early days, reflections were faked by using either a pre-rendered image or in the case of mirrors, just copying the entire level and flipping it. This is a great example of how expensive it is to render reflections in games as it’s cheaper to run two entire levels. Like the lighting, this moved on to reflections that were worked out in real-time, but not of great quality. Now with real-time ray tracing, we can do near-perfect reflections in games at a reasonable performance cost.

How Can You Use It As A Gamer?

To utilize ray tracing, you need certain hardware. The latest generation of consoles is capable of using ray tracing in their games. If you are a PC gamer then you will need a graphics card capable of running it, such as the RTX line from Nvidea or the RX series from AMD. Trying to use older cards may result in issues or cause very poor performance, as this technology requires a lot of computing power to run.

Epic Games Demonstrates Real-Time Ray Tracing in Unreal Engine 4 with  ILMxLAB and NVIDIA - Unreal Engine
Unreal Engine – Epic Games

Then all you need is a game that utilizes it. Unlike other technology such as HDR, you don’t need a expensive TV or monitor to run it, as it is all done on the computing side of things. More games are beginning to use ray tracing, and most AAA games will use it as standard, although smaller games such as those without dedicated lighting teams may not use it, as it requires finessing and optimising. Soon it will be the standard way of lighting though, as computer power continues to increase.