[Gear VR] Dynamic lighting doesn't work at all

I figured it would be nice trying to have one directional light, non-shadow-casting, to bring out normal maps on movable actors.

Turned out that dynamic lights don’t work at all on Gear VR (I suspect they don’t work on Android, period)

Did more testing and dynamic directional lights do not work on Gear VR (or perhaps on mobile in general).

Stationary lights do work in 4.12.4, but require distance field shadows for static lighting, which is a performance drainer compare to lightmaps.

Hello ,

I have a few questions for you that will help narrow down what issue it is that you are experiencing.

Quick questions:

  1. Can you reproduce this issue in a clean project?
  2. If so, could you provide a detailed list of steps to reproduce this issue on our end?
  3. Could you provide screen shots of any blueprints/settings that may be involved?
  4. Could you tell us what device it is that you are using?
  5. Could you also provide the exact OS that is currently running on the device?

Hi Rudy,

I am gonna have to try creating new project and testing it.

Steps are simple - create BP FPS template, place static meshes (set them to cast dynamic shadows), make them Static, set directional light to be Stationary (affect world, cast dynamic shadows; play with distance settings, etc.), build, play in PIE - shadows are there. Then deploy to S6 (is what I use) and observe no shadows.

I am using T-Mobile’s Galaxy S6 64Gb, Android 6.0.1

Hello ,

Were you able to reproduce this issue in a clean project?

Sorry, not quite yet. Been dealing with my launcher connectivity report, Gear VR performance and Oculus FMOD issues with UE4.

I’ll get to this one pretty soon!

https://s32.postimg.org/nwm2jfw05/com_Company_FPS_Template_4125_20160712_234415.jpg

FPS Template, UE 4.12.5, everything is default, directional light is Stationary with static and dynamic shadows.

White boxes are movable, gray - static.

As you can see - no shadows from movable objects on the device. There are shadows in PIE, even in ES2 mode, but not on the device.

In my other project (the one I PM’ed you) I don’t get even static shadows with Stationary directional light.

Hi , I can only get dynamic objects to cast a shadow on mobile if I set the directional light source to also be moveable. Not stationary.
If I add a cube to the level, set it to simulate physics and set the light source to moveable, I get dynamic shadows on mobile.
Also remember to build your lighting.

Cheers,

TeamKingdom

I did build lighting and someone from Epic advised on using Stationary light and not fully dynamic. When using directional moving light performance is atrocious.

Hello ,

As a quick test could you try enabling Cast Modulated Shadows and let me know if this makes any difference on the device?

Hi Rudy,

Nope, no dynamic shadows from movable actors on the device with modulated shadows on.

Btw, I think there are bigger issues with Stationary lights - I was messing with settings of the light in ES2 mode, turned off dynamic shadows, turn them back on and shadows were gone :confused:

Then I closed project, reopened it (with SM5 preview by default) and shadows were still gone :confused:

So now I don’t have dynamic shadows at all, not in PIE, not on the device.

Yep, I did set it to Stationary. Initially, when I just set the project up, I did have static shadows from Stationary light, but no dynamic shadows. When I ticked Modulated shadows, I got some nasty “shadows” in PIE, so I turned that off.

Then I played with various settings, and ended up without any dynamic shadows in PIE (not even modulated).

I’ll see about uploading that project. It’s not that big in size.

Just wanted to double check, but did you have your Light source set to Stationary? Modulated shows requires the light to be Stationary.

Hello ,

I wanted to check in on the progress for the project that you mentioned above. I was wondering if you had an example project that reproduces the issue mentioned here?

Yep, ready.

Here is the video of what I see in ES2 PIE:

and here is the project:

Also worth noting that the project I sent you via PM on the forums has no shadows at all, with the same setup I got going in this project I linked above.

After further testing with the project provided I believe the following information may help.

Information:

  1. You need to enable “Receive combined static and CSM shadows” when using stationary light. This needs to be enabled on ALL static meshes you want to receive both shadow types.
  2. In your directional light source you will need to disable “Inset Shadows for Movable Objects”.
  3. If you would like to use a fully dynamic light (no baking), you will need to set the light to Movable, and adjust the Shadow Distance. However, dynamic lighting will largely be dependent on the device and it’s specs

Thanks Rudy, I will do some tests using your suggestions!