Backlit particles?

So something I’ve been wondering for a while, what kind of shader do you need to get that cool edge highlighting from backlit clouds?

I’ve seen several games do it, some from quite a long time ago even.

World in Conflict:

Just Cause 3:

Even the original Crackdown had it:

I’m still fairly inexperienced when it comes to shader writing, so I’m curious how something like this is done.

The first question is if it’s for a skybox or if you’ll see the clouds from the lit side as well. Two very different beasts.

In all World in Conflict and Just Cause 3 the clouds are all actual billboard particles that you can move the camera around in all directions.

The only one I’m not so sure on is crackdown, it looks like they may be using something other than just billboards.

Easiest way to achieve this in the shader would be to calculate the light a second time (this part is quite engine dependent) but with negative normals, then multiply that by 1-alpha.

Other method is to use a bias when finding your facing ratio, then in your main lighting pass it’ll appear as if the normals wrap around the particle a bit more. Hopefully that made sense

Hmm, I get what you’re saying for the first method, though I’m not sure how the second method works.

Any idea if an effect like this would be possible in UE4?

In udk using transmission mask & color can make these effects

But in ue4 there’s something difference between udk’s transmission and ue4’s subsurface color. It doesn’t work properly with translucent.

1 Like