Where is the "Custom Lighting" pin?

I have a material set up for my sky box that I’m trying to implement in UE4, originally from UDK, and it uses nodes to create and control the sun based off of default lighting. My issue is that it requires a pin in the material for “custom lighting” which I can’t seem to find and there’s no selection under the material to use it. Anyone know a workaround or something of the like?

Hey NullFX -

UE4 uses Deferred rendering, so the materials are rendered out first then the lighting is applied to the rendered elements. However, you can create dynamic material instances in blueprint and access the light vectors and other rendering information from that interface. My suggestion would be take a look at the skybox in the opening starter levels of UE4, they show a great way of passing light information from blueprint to the level’s material.

Hey colin.avrech -

For clarity, can you please make a new question and while you do that I will try to work out an example for you.

Thank You

Eric Ketchum

It would have been great if the Custom Lighting pin could have been made available but not used if deferred rendering was in use (i.e. so we could still use custom lighting on mobile). Currently on mobile in order to get something basic like 2-tone / cel shading, you have to use all unlit materials with a parameter for the light direction (post process is still too heavy in any reasonable project on anything but Metal devices)… unlit materials mean no shadow casting or receiving, and every lit thing in the world has to use a dynamic material instance that gets updated with light direction.

Anyway, I suppose Metal-equivalent devices will be the norm in future, so it’s probably a bit late for this to be useful. Though I see forward rendering is being used again for VR?