Substrate - Feedback Thread

  • Trying to open SMF_UE4Unlit crashes the engine in 5.2p2. Also can’t actually use the node, it won’t plug in anywhere. Guessing those two issues are related.
  • Rect lights have no specular response when anisotropy is set to non-zero. This is also true of the legacy implementation, I’m just wondering if this will be improved at some point? Even having it behave like a point light would be better than having no specular at all (feel free to ignore if this is not Strata related)
  • Planar reflections don’t appear to render with strata enabled (5.2p2). I know planar reflections are sorta undesirable but right now it’s the only way to get mirror reflections on platforms without hardware raytracing, especially if you are using lightmapped gi.

It would appear that a sphere is treated in UE Strata/Substrate as if it was thin-walled. How would one achieve refraction as if a mesh was a solid thick glass surface? With a solid sphere, one would expect the image to be flipped. For example in the Arnold render below the sphere on the left is thin-walled and the sphere on the right has an IOR of 1.33

2 Likes

I actually think you have found an edge case in how the model is parametrized. You have a MFP of 1 in the transmittance to mean free path color for the blue channel - meaning that blue light is not attenuated at all. Simply changing the blue channel of your vector parameter to 0.99 will give the behavior I was expecting.

Noticed this happening with any full saturated color going into the MFP color. A fix is to insert a (de)saturation node and set it to 0.99 as you said. I wonder if it might be good to build that into the shader? After all, artists will crank the color sliders all the way.

@Arkiras
1- Unlit material function crash is solved in 5.3
2- Rect lights: that is something we would like to improve but not ETA (and not dependent on Substrate).
3- I have checked and it was missing indeed. Now it will be coming in 5.3.

Thanks!

1 Like

This is not related to substrate but to the way refraction is evaluated.

However we do want to improve the that part and already have: (A) by default we have distortion follow the material properties (F0/IOR/refraction assuming thick mesh) while (B) being overridable on the root node. And (C) We also have rough refractions available with Substrate. The thin shell behavior is also something in the todo list but no ETA.

Found an issue with transmission on a light causing artifacts on a material with subsurface scattering.

Steps to reproduce:

  1. Turn on “transmission” on a light (light set to moveable).
  2. Make a material with SSS.

The material here is quite simple. It has a color going through a Transmittance-to-MPF where the color going in has a value below 1.

When it the value is set to 1 you get fireflies in a bottle:

I’m seeing this on both Slabs with MFP (The head on screen right in the image below) as well as on a Slab with SSS Profile (the head on screen left).

I do not see this on a Surface Profile material in UE5.0. The above was tested in UE5.1.

Is this a known issue, and are there any workarounds to get back-scattering with Strata? Forward-scattering works wonderfully!

Hi,

There are potentially several things at play:

  • Shadow map type: What type of shadow are you using? SM/VSM/RT? In your 5.0 / 5.1 comparison are you using Virtual Shadow Maps in both cases (vs. regular Shadow Maps)?
  • Thickness: The thickness evaluation, used for computing the light transmission for ‘diffused’ SSS (i.e., SSS Diffusion or SSS Profile Diffusion) it not handle similarly for the Profile vs. non-profile version. The profile version will use the SSS Radius, while the non-profile version will use its ‘max’ MFP value. This is an known issue on our side that we need to address.
  • Type of light: Does this happen for both local light and directional light? Or just with local light? We could be missing some logic on point light.

Thanks.

/Charles.

Hi.
I’m not sure if it has been answered already, but in order to get reflections on a glass material, you need to change the “Lighting Mode” under “Translucency” from “Volumetric NonDirectional” to “Surface ForwardShading”.
Also make sure that your F0 value is not completely black.

I hope that helps,
Daniel

General questions concerning glass.

Hello
First time playing with Substrate (and not that much longer with UE), so there is a very high chance I’m doing things wrong.
I tried to achieve a glass material and applied it to several objects.
There are several issues I’m seeing in the viewport.
Most apparent is the very thin cube in the front that acts as a “window”. Thickness is 0.01. So very thin, but double-sided.
The refraction feels more like a very big volume of glass though. You can see how sharply that rock and trash bag gets cut off on the right.
Also, the platform on the bottom is “getting pushed back” really far.
The secondary material on the shader ball is getting pushed outside the actual geometry. The “U” emblem is appearing behind the shader ball when looking through glass.

Here’s also a screenshot of my setup.
Blend Mode is set to “TranslucentColoredTransmittance” and Lighting Mode is set to “Surface ForwardShading”.

Any input on these issues is highly appreciated.

Cheers,
Daniel

Hi @un1cornwarrior

“Surface ForwardShading”

This a normal level of quality selection we have and work like that without Substrate too.

the platform on the bottom is “getting pushed back” really far.

There is no issue I can see, this has also always been working like that.

=> Refraction in real-time is impossible to get right because we cannot trace for real. We always assume a thick surface in real time since we cannot trace and assume anything so far.
=> So artists are thus in charge of the refraction direction and strength. According to selected mode:

  • IOR deducted from material specular properties but can be overriden on the root node
  • PixelNormal using fake refraction from normal and view
  • 2DOffset completely independent from the surface normal, aka you do specify the offset you want).

Simply select the refraction mode that suites you and tweak the Strength and parameters. Documentation for you to read, this is the same with/without Substrate… (2d offset will be added soon to the documentation).

So currently, using IOR mode you thus have to lower the IOR close to 1.0 in order to approximate the fact that this is a thin object.

Thanks so much for your feedback.
Changing the refraction mode from “IOR” to “PixelNormal Offset” helped a lot to get a more natural look, as seen in the screenshot below.

But when I increase the “roughness” now to 0.5 for example, the glass gets blurry, but the refraction of the glass object behind the thin sheet appears weird.
Due to the roughness, the reflection intensifies but doesn’t get blurred when seen through another sheet of glass.

Any advice on what might cause this?

Cheers,
Daniel

1 Like

Hi Charles,

thanks for your reply and the pointers.

Virtual Shadow Maps in all.

Virtual Shadows


Indeed the jagged edges is definitely connected to the shadows.

Above is SSS Profile on the left, and MFP on the right. Back scatter on the ears is nice, but we get jagged edges on the shadows.

Raytraced Shadows

In comparison, with ray traced shadows,

  1. We do not get the jagged edge, but do get an abrupt hard edge. Compare these shadows to the sphere where SSS is off.
  2. Back scatter is hardly there at all. Just little blotches of red.

In comparison, here is a Subsurface Profile in UE5.0 with ray traced shadows:

Good to know, thanks. I find I’m able to get pretty good control of thickness in the two using a Transmittance-to-MFP helper for both the color and thickness.

I note that the SSS phase anisotropy defaults to 1. This results in 100% forward scattering. So I have it set to 0.8 here in these examples.

Directional Light

With a directional light I don’t get the jagged edges, but do get illuminated blocks. These blocks change (pop on and off) as the camera gets closer to the object, and disappear at further distances. I believe this is related to virtual shadow mapping.

Rect Light

For a Rect light, turning transmission on or off on the light appears to have no effect. Rect Lights do not work with transmission in UE5.0 either.

FWIW, in animation and VFX lighting (my background) a rect light is the go-to light to get rim light and thus back scatter on characters. So I was surprised that of all the lights, this was the one it does not work with. Perhaps this is because the Rect Light is relatively new to UE?

On a related note, I’ve been able to implement the two-sided foliage material by:

  1. setting the root node to two-sided
  2. setting the blend mode to masked.
  3. setting the slab “use Subsurface Diffusion” to OFF so it uses wrap-approximation
  4. plugging the subsurface color into the color input of a Strata Translucence-to-mfp, and putting a value of 0.01 into the thickness input

Comparing this to a two-sided foliage material with the Strata Legacy Conversion, this gives me the same appearance in a new Slab. I get translucency through the leaves, without needing to have transmission enabled in the light.

However with directional light I am seeing the blocky artifacts that I mentioned previously (again transmission is off on the light). This happens both in the new Slab and in the Legacy Conversion material.

image

Is anyone able to replicate this? It could just be that something is wrong with my settings for virtual shadows.

1 Like

r.Shadow.Virtual.SMRT.TexelDitherScaleDirectional

try raising this value, it helped in my case but as the help for that cvar says too high value might cause some shadow light leaks.

1 Like

I’m tempted to convert a VR project I’m working on to substrate. Anyone knows if substrate works well in VR and if performs well?

EDIT: I tested it and it’s glorious. Had to change default VR pawn material as hands were flickering all colors for some reason :smiley:

EDIT2: Ok subsurface is doing something wrong in VR.

happens only with foveated rendering enabled

Hi to everyone :slight_smile:

I am enjoying testing new substrate material, although I’ve came across some strange error when turning on Raytracing translucency on both of my machines (3080 latop and 3090 desktop). You can check the screenshots.

Hello,
Substrate does not work with raytraced translucency (as mentioned on the documentation) . Lumen (which includes ray tracing) is the future proof way forward for this.

Does this mean effects like inverted refractions in spheres is not possible with substrate? Or will these more physically correct refractions be possible with raster translucency in a future state?

I noticed in the 5.2 examples project that there were some odd flickering on the eyeball shader -

And same thing for the two sided example

Windows - RTX 4090

Hi @un1cornwarrior thanks for the tip. The issue was that there was no Skylight in the scene. After adding it everything worked as expected.

edit: Try using a Fresnel falloff for the refraction intensity this helps with some of the issues you encountered.

1 Like