Cyberpunk 2077

File information

Last updated

Original upload

Created by

Phenomenum

Uploaded by

Phenomenum

Virus scan

Safe to use

About this mod

Plain and simple INI tweak to adjust shadows distance and detalization with zero perfomance impact.

Requirements
Permissions and credits
Changelogs
First of all, i want to thank stoker25 for uploading extracted INI settings - without this i've never know what to change.
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
This simple tweak allow to modify Cascade shadows distance in order to get more detailed shadows. More small objects will cast shadows on the distance. Perfomance impact is quite negligeable.

Disclaimer: If you're using RT-shadows, you will see no difference. Cascade shadow maps belongs to classic rasterization rendering and have no relation to Raytracing.

Let's start from scratch: how CP 2077 shadows works? This game using two types of shadows:

1. Cascaded Shadows. Rasterized shadow map divided into 4 "cascades" (0,1,2,3), and descreasing resolution with every next cascade. Cascade shadows processed by some kind of blur filter for nice soft look and have a smooth Time of Day transition. When the last cascade is over, the next shadow type go to work...
2. Distant shadows. Also a rasterized shadow map, but have no nice blur filter, and have no smooth ToD repositioning - shadows change their position every 2-3 seconds. Looks very ugly and pixelized.

The good news: we can safely stretch "cascades" without noticeble shadow quality drop, and bring a details to close and mid range shadows by stretching higher resolution shadow maps a litlle further than vanilla settings.



1. Go to CP 2077 install dir\engine\config\platform\pc.
2. Create a file named user.ini (or you can get any of .ini files in directory, copy and rename it, then past back under a new name).
3. Open your file, type or past (if you already have an user.ini, just add these parameters at the bottom of file):

[Rendering/Shadows]
CascadeRange0 = 12.000000
CascadeRange1 = 30.000000
CascadeRange2 = 75.000000
CascadeRange3 = 140.000000

4. Save file and start the game.

In Files section you can find my own user.ini file, if you want a ready solution.

Comparison 1
Comparison 2

Increasing CascadeRange3 from vanilla 100 to 140 (150) gives you a soft shadows, with smooth transition, instead of pixelated and jerky vanilla distant shadows in most scenes. Look at the moving shadow on red building in the center of the screen.

Vanilla


Tweaked


All values in my user.ini based on my personal preferences and a not mandatory - you can change them according to your taste, but remember: it's a shadow maps with fixed resolution, so don't stretch them too far (don't use big values) - otherwise you loose details. Also, i highly recommend to use "High" Cascaded Shadows Resolution in game options.

CascadeRange0 - the closest to player and most detailed shadow map.
CascadeRange1,2 and 3 - shadow maps for more far distances, accordingly.

If you find my shadows are too sharp, you can use this:

[Rendering/Shadows]
CascadeRange0 = 12.000000 - this parameter will push the nearest cascade border away from player
CascadeRange3 = 140.000000 - this parameter will stretch last "cascade"  and fix pixelated distant shadows in most scenes (watch my video)

I've added optional user.ini with only two fixes. Still, compared to my main tweak, mid range shadows will be less detailed and accurate, and small objects will not cast shadows on the distance (vanilla issue).

CascadeRange0 Before/After comparison
-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

Original INI values are:
CascadeRange0 = 6.000000
CascadeRange1 = 20.000000
CascadeRange2 = 50.000000
CascadeRange3 = 100.000000

If you want to revert back vanilla shadows, just delete user.ini file or delete [Rendering/Shadows] section if you using other INI tweaks.