Summary
Tested under 5.8.1, AMD Ryzen APU. Reproducible across DX11/DX12/SM5/SM6. Under forward renderer, when moving the camera back and forth quickly focusing a spot light or a point light which is not covered by a directional light, flickering black line will occasionally appear across the lit up area.
What Type of Bug are you experiencing?
Rendering (Graphics / Niagara)
Steps to Reproduce
Create a new project, switch to forward rendering. Delete lights like sky light and directional light and place a point light. Then move the camera back and forth focusing the lit up area.
Expected Result
Without black line artifact.
Observed Result
You will see the flickering black lines. It is easier to see if turn the light brightness is high.
Affects Versions
5.8
Platform(s)
Windows
Additional Notes
Asking about the issue on Discord, I got these observations from Uno “Wild Ox” so I will just paste them here. Hope it can help. Thanks Uno “Wild Ox” for the help.
“Strongest candidate: the shader preprocessor buffer-sizing change, commit 343e81e1b7cb (”[shaders] fix 1-byte null terminator overflow in preprocessor copy loops…"), Engine/Source/Developer/ShaderPreprocessor/Private/stb_preprocess/preprocessor.c:
Two copy-loop capacity calculations got +1 added for a NUL terminator (reasonable, targeted fix).
But a third site, in maybe_expand_macro (used when expanding a macro’s replacement text into a temp buffer), had its capacity changed from src_length + 512 down to exactly src_length — all safety padding removed, not even the SSE_READ_PADDING (16 bytes on SSE builds) that other call sites keep. The commit message calls the 512 bytes a “hack…added to work around the 100% mac crash,” but doesn’t explain why zero padding is provably correct for macro re-expansion, where the copy routines can write past src_length legitimately (that’s the whole reason the other two sites got SSE_READ_PADDING + 1, not +1 alone)."
“shader preprocessor macro-expansion buffer under-allocation in maybe_expand_macro (Engine/Source/Developer/ShaderPreprocessor/Private/stb_preprocess/preprocessor.c, commit 343e81e1b7cb), affecting forward-shading’s macro-heavy local-light permutations, reproducible across DX11/DX12/SM5/SM6”