Distance fields not working on lower end computers

Hey, I’m making a game in 5.4 and a few materials use the DistanceToNearestSurface node to calculate their opacity. This works perfectly in most scenarios, but some player’s lower end computers seem to not be creating/using/displaying distance fields for the materials to use.

The materials show as either invisible, or fully opaque, as opposed to only being visible or invisible near surfaces like they should be. Is this a known issue with distance fields? Do I need to set a default setting somewhere to never have distance fields turn off? Or is it an issue with the DistanceToNearestSurface node?

Any help would be great cause I can’t find any real info about this happening anywhere.

I see this

but as usual, the AI has attached the wrong article for it.

I’m also thinking where distance fields sit in the engine scalability settings. That would also have an effect.

EDIT: I just read that distance field calculation is stripped out unless you’re on High or Epic.

I recommend testing it for yourself, because I think that’s incorrect.

Hey thanks! Yeah I saw that same response from AI too. But the only place I see actually mention is the official documentation, but they give literally no other details about that fact.

I’ve been able to figure out that it’s specifically the Global Illumination quality that’s effecting it, but only on low. And within that setting specifically r.DistanceFieldAO is the command that’s turning the distance fields on or off.

I’ve testing it specifically by setting the GI to low, then entering the command r.DistanceFieldAO 1, and it turns distance fields on and makes the materials look how they should even while still on low settings.

BUT I can’t get this to work in the packaged build. I’ve tried using the Execute Console Command BP node in multiple places (level BPs, player BP, and game instance init event) and none of them worked.

I’m also having a separate problem though where anytime I add a line in a .ini file for setting this command, then I package the build, it resets the .ini file back to how it was before I added the line. If I’m able to figure out what’s causing this do you think it could solve the distance field issue?

AND (sorry I know this is a lot) I am testing this on a laptop with integrated graphics, so for all I know this is entirely a waste of time. But if that’s the case, shouldn’t there be SOME more info out there about a very common effect being entirely useless on a ton of hardware? (It’s Intel UHD graphics btw if it might matter)

What unreal engine version are you using? Unreal had all distance field stuff disabled when using an Integrated GPU for many years. I think a few versions ago they changed it to check for SM6 support in iGPU. And in 5.8 they removed the check entirely. So you can try UE 5.8 and see if it will work for you there.

From 5.8 Release Notes : “Allow distance fields to run on GRHIDeviceIsIntegrated. This check was added a decade ago to prevent issues on some outdated drivers, but nowadays it prevents some pretty capable SM5 GPUs to run distance field features.”

If you can get the DF working on this potato in the editor, I think it should be possible when packaged.

I’ve found that using the console command before changing scalability does the trick, but that was with Lumen overall.

I use

sg.GlobalIlluminationQuality 3

after that, changing to low seems to leave the GI alone.

I don’t know if this will work with DF.

I’m using 5.4. I’m pretty late into development so I really need to avoid upgrading versions so I don’t think that’s a great option for me. I did test it though with another project and yep, distance fields absolutely work with 5.8 packaged builds.

For something as simple as a check, do you think there’s any way I can bypass the check in 5.4? Or would it be entirely only baked into the version?

if you mean like a checkbox / toggle somewhere or Cvar, then probably not. As far as i know it was hardcoded since 2017 or so.

I found this commit in UE 5.5 :

https://github.com/EpicGames/UnrealEngine/commit/1b1b3285c9d2585cddcc14a37e55d133a1709337

And this one in 5.8 :

https://github.com/EpicGames/UnrealEngine/commit/60de958d674373f13545ce838795a9a486139d0f

so the only way to make it work without updating would probably require you to delete these checks yourself from the engine code…

as an alternative you can test UE 5.5 too. Maybe SM6 support check will be enough for your use case. Then if it works you only have to update from 5.4 to 5.5 (instead of 5.8).

Gotcha, thank you for looking into it! I’ll probably experiment at least, but I may just end up finding another way around it at this point.