Shaders are not compiling on packaged build.

Hello nice people,

I need help.

this was working before now it’s not. so i’m sure it’s something i’ve changed or my environment.

i’m using 5.6.1.

when i’m packaging, the shaders do compile during cooking.

when i run the game and change the quality level using the standard ue quality scalability settings, it tries to compile the new shaders but it does nothing. the process for "ShaderCompilerWorker” does not even start.

if i change the scalability on the editor, it does compiles the shaders normally.

these are my pso cache settings, i thought this could have an effect, is the only thing i remember tweaking lately.

[DevOptions.Shaders]
; used by pso precache
NeedsShaderStableKeys=true

[/Script/Engine.RendererSettings]
r.Water.SingleLayer.ShaderSupportVSMFiltering=0
r.Water.SingleLayer.VSMFiltering=0

; pso precaching https://www.tomlooman.com/psocaching-unreal-engine/
; https://dev.epicgames.com/documentation/en-us/unreal-engine/pso-precaching-for-unreal-engine
; https://www.youtube.com/watch?v=i35yf-wh3Bs
; https://dev.epicgames.com/documentation/en-us/unreal-engine/optimizing-rendering-with-pso-caches-in-unreal-engine
; https://dev.epicgames.com/community/learning/tutorials/xjzE/unreal-engine-epic-for-indies-game-engines-shader-stuttering-ue-s-solution
r.PSOPrecaching=1

r.PSOPrecache.ProxyCreationWhenPSOReady=1
;0  Skip the draw until the PSO is ready.
;1  Fallback to the engine's default material until the PSO is ready.
r.PSOPrecache.ProxyCreationDelayStrategy=0

; // Skips the draw command which is at a different stage from the Proxy Creation skip below. This may cause artifacts as part of the object could be rendered if split among different commands.
r.SkipDrawOnPSOPrecaching=1

; don't emit until pso ready
fx.Niagara.Emitter.ComputePSOPrecacheMode=1

i greatly appreciate any help. as this is a breaking issue on my game.

ok, i got this useful log (not sarcastic). i’m still trying to figure out what’s going on.
i got like 10 of these logs. some repeated on other meshes.
[2025.10.19-05.45.35:326][881]LogMaterial: Error: Tried to access an uncooked shader map ID in a cooked application [2025.10.19-05.45.35:326][881]LogMaterial: Warning: Invalid shader map ID caching shaders for 'GhostFB_DM', will use default material. [2025.10.19-05.45.35:326][881]LogMaterial: Can't compile GhostFB_DM with cooked content, will use default material instead [2025.10.19-05.45.35:326][881]LogMaterial: Warning: [AssetLog] /home/nande/work/repos/LifeDev/Build/Linux_dev/LifeDev/Content/LifeDev/Game/Env/Ghost/GhostFB_DM: Failed to compile Material for platform SF_VULKAN_SM6, Default Material will be used in game. 

i’ve changed the packaging settings to only cook specific levels. the materials don’t change, but maybe when i change the quality it uses different material functions.

but i would have expected that the cook process will account for all quality levels.

edit:

changing the setting to cook all maps still has the same error.

edit2:

it seems it was due to checking “discard unused material qualities”

r.DiscardUnusedQuality=True


which is odd, because they are used, or maybe i misunderstood how it works.

anyway i need to verify properly tomorrow.

Hi @nande ,

The problem is you are trying to use VULKAN and Shader Model (SM) 6 most can only use SM5

To actually get this to work you should use Direct X 11 or Direct X 12

If you type DXDIAG in windows search box then when running use Display tab and see what your Graphics card is capable of running.

1 Like

Hey Jim, thanks a lot.
Actually SM5 and 6 works well on my machine. so that was not the issue.

i did more tests and it turns out it was caused by the flag

apparently i don’t understand well the side-effects of it yet.

seems to be a packaging optimization for games/apps that do not change the scalability settings.

or maybe i’m missing something.

Thats chatgpt or an llm right?

Please disclose it because they hallucinate.

You get a warning on their site, but if you dont disclose it you are hidding such disclaimer to other people.

Unfortunately that information is quite incorrect and doesnt really clarify my doubt or explains much. I prefer others’ human experiences.

Thanks for the help though.

1 Like