You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Soft shadows currently exhibit banding artifacts, instead of appearing smooth.
Screenshots
Notice how there is visible banding around the edges of shadows:
Possible solutions
The current implementation of soft shadows uses PCF (Percentage Closer Filtering), which involves sampling multiple pixels of the shadow map and averaging their shadowed/unshadowed results. The most obvious way to reduce banding is to increase the number of samples, but this appears to cause a noticeable performance impact while still not looking smooth enough.
Modern GPUs support hardware-accelerated shadow smoothing (linear interpolation), exposed in OpenGL through sampler2DShadow, which samples an area of 2x2 pixels. This article describes a possible way to leverage this capability, while still being able to sample a larger area, to allow a configurable blurRadius.
The text was updated successfully, but these errors were encountered:
Description
Soft shadows currently exhibit banding artifacts, instead of appearing smooth.
Screenshots
Notice how there is visible banding around the edges of shadows:
Possible solutions
The current implementation of soft shadows uses PCF (Percentage Closer Filtering), which involves sampling multiple pixels of the shadow map and averaging their shadowed/unshadowed results. The most obvious way to reduce banding is to increase the number of samples, but this appears to cause a noticeable performance impact while still not looking smooth enough.
Modern GPUs support hardware-accelerated shadow smoothing (linear interpolation), exposed in OpenGL through
sampler2DShadow
, which samples an area of 2x2 pixels. This article describes a possible way to leverage this capability, while still being able to sample a larger area, to allow a configurableblurRadius
.The text was updated successfully, but these errors were encountered: