I am trying to build a shader which is passed to the “GlobalPostProcessVolume” but currently it affects the whole screen.
Is it possible to have the shader effect only affect a specific region in the world? i.e. just objects within a specified radius around the coursor (trying to have some kind of fish-eye distortion around the cursor).
So something like a per-object-shader?
thanks in advance
It is possible. Within limited margin. PostProcess still a “post” process. It’s applied to a rendered image (like a photoshop filter).
You could use Custom Depth to render a mask for your object.
Here’s a links that may be useful:
Unreal Engine 4 Tutorial - Basic Object Outline (Interaction)
Unreal Engine 4 Guide - Actor visible through walls
Tom Looman - Outline Effect in Unreal Engine 4
As for mouse position you could use Get Mouse Position node and feed this info to shader by Dynamic Material Instance parameter.