This is how GTA 5 renders a frame

I found it to be quite an interesting read, especially this part:

Depth map:
Intuitively you would expect far pixels to be white (depth of 1) and closer pixels to be darker. This is not the case here: GTA V seems to be using a logarithmic Z-buffer, reversing Z. Why do this? Due to the way they are encoded, floating point numbers have much more precision when closer to 0. Here, reversing Z leads to more precision when storing the depth of very distant objects, hence greatly reduces Z-fighting. Given the long draw distance of the game such trick was necessary. It’s nothing new though, Just Cause 2 for example was using a similar technique.

The whole article goes on for quite a while, explaining virtually everything in the following two parts.


very interesting thanks :wink:

Do they explain why after 20 minutes of playing my fps has dropped from solid 70 to 25?

Indeed interesting.
4100 drawcalls using 1100 textures is quite a large amount.

They mention that it’s stable even after running for hours, which is also my experience. One of the possible options is that your cpu or gpu gets so hot that it throttles back its speed. I had to go buy a custom cooler for my cpu, otherwise it got to 100°C after 5 minutes of playing (it was summer though).

I was under the impression it was a memory leak, maybe not though. Luckily the games story and characters are weak imo so I lost interest once I was done with the missions