Imitating Disney’s Dr. Facilier Shadow in UE4
Events
Subscribe:  iCal  |  Google Calendar
Busan KR   15, Nov — 19, Nov
Minsk BY   15, Nov — 17, Nov
Minsk BY   16, Nov — 19, Nov
Philadelphia US   30, Nov — 3, Dec
California US   4, Dec — 6, Dec
Latest comments

I lost a year's work when Microsoft deleted my documents folder on their October update I wish this guy luck Adobe are more interested in forcing professionals to use their cloud than improving their products these days.

Balance changes please!

by Juan Milanese
6 hours ago

Another incredibly useful breakdown, thanks Simon!

Imitating Disney’s Dr. Facilier Shadow in UE4
15 March, 2017
News
Tom Looman presented his experiments with Forward shading in Unreal Engine 4 inspired by Dr. Facilier’s shadow in The Princess and the Frog. 

Enabling forward rendering changes UE4’s default deferred pipeline. Here is Tom’s result:

The implementation is really quite basic, I used the LightAttenuationTexture available only in Forward-rendering of the engine to find which part of affected by light. To access this buffer you need to use the Custom-node in the material editor, and apply the following code:

return Square(Texture2DSampleLevel(LightAttenuationTexture, LightAttenuationTextureSampler, UV, 0));

“UV” is an input parameter (so make sure it’s added to the param list of the custom node) in which we feed the ScreenAlignedUVs node output.

For those interested, I found this snippet in the engine’s shader folder at …/4.14/Engine/Shaders/Common.usf and contains the function  GetPerPixelLightAttenuation(float2 UV);

Tom Looman

The material used in the GIF:

Make sure to read the full post on implementing forward shading inside UE4 here

Source: Tom Looman

Leave a Reply

Be the First to Comment!

avatar
wpDiscuz