Drunk & High😵💫
HLSL ShaderI made this drunk shader because I was inspired by a lot of drunk effects across AAA games, this is a screen space camera effect that applies the following effects :
- RGB Shift
- Ghost Images
- Wave Distortion (Amplitude and Frequency Distortion)
- Radial Blur
Material and Shader Integration
- The effect is applied through a custom material that processes each pass.
- Blit operations run in different shader passes (pass indices 0, 1, 2, etc.).
- The shader modifies:
- cameraColorTarget to read from and write to.
- Multiple buffers to accumulate the distortion effect.
Performance Considerations
- Uses temporary render textures (cmd.GetTemporaryRT) to minimize GPU memory overhead.
- Avoids unnecessary depth buffer calculations (desc.depthBufferBits = 0).
- Configurable quality settings (adjustable shader parameters) allow optimization based on hardware capabilities.