Download

UE4.12.5 - Dynamic shadows not working + On ISM material is not rendering

Hi all,

I’ve updated my GearVR projects to use UE4.12.5 and I’m having some issues.

I followed the guide on mobile lighting using CSM as shown here, but as soon as I package the project and run it with the GearVR dynamic shadows are nowhere to be found :frowning:

I tried to enable/disable the “Insert shadows for movable objects”, tried to change the settings in the CSM, but still nothing…HDR is disabled and the scene is veeeery simple ( it is the third persona starter pack with some additional movable cubes and spheres )

Also in order to reduce draw calls I created an ActorBP, use an Instanced Mesh and created a setup ( using the construction script ) which allows me to clone the ISM using an end point and dragging it around.
In the viewport I can see everything clearly, in the ES2 preview as well, but as soon as I package the project the material is not rendered.

The scene is quite simple, there’s a ISM on the left, a floor and 80 ISM on the right ( cloned using the construction script ), to test the efficiency of the system, but if I run Stat Engine I can see the draw calls count rising and ( I think this is obvious but I wasn’t sure ) the polycount rising as well ( the base mesh is 30 triangles )

Since the tutorials and documentation about the Instanced Static Mesh is very basic a sample or a tutorial would be great :slight_smile:

Thanks

Welcome to the club :frowning:

If you use Stationary directional light and Modulated shadows (and actors set to movable instead of static; although I don’t recall if this step is necessary), you will have instanced meshes render properly and have shadows. The problem is that it’s performance taxing, at least on my S6.

Good answer :smiley:

The character and the cubes/spheres are all movable, while the walls are static, and those are the ones without material, but also without dynamic shadows I still have the mesh being rendered without material, which is pretty annoying…
I will try again later today and see if there is something else I’m missing :frowning:

Dynamic shadows are actually just for testing, I’m not planning to use them in my project but at least I would like to see them in action

Quick update:

I managed to have my ISM to build a kind of array and, surprisingly, it works!..on just one of them…I duplicated the same ActorBP ( a floor ) and replaced the mesh inside the ISM ( replaced with a pillar ) and, when the package is built, the mesh is completely black…I have no idea whats going on :smiley:
Also, even if I override the lightmap resolution to 32 on the floor ISM, after the lighting is built I still have the “Lightmap too large” warning ( there are like 12 ISM ), but overall the performance, in the same scene I tested earlier, are surprisingly steady at 60fps ( on 90% of the stage ).

As I was doing those modifications and built the project, as soon as I hit “Android ETC2” there’s an unknown error and I can’t built the project…but if I right click on the map and migrate the entire project to an empty one ( or if I simply migrate the entire content into a backup version of the project I was working on ) I can build the project without any issues.

Man, figuring out what’s wrong sometimes its just a matter of find a workaround :smiley:

So your ISMs are still black ?

While workaround is a fine thing, it just shows how far behind Gear VR support is lagging compare to PC/consoles and even mobile. Sad :frowning:

One of them ( pillar ) is still black, the other one ( floor ) is being rendered, still don’t understand why, since the setup and the settings are exaclty the same between them.
I’ll try to build it from scratch to see if the situation change, but the point for me will be to understand what’s going on…also because with 12 mesh my lightmap is too large?
I thought that using ISM would solve the draw call issue, but at this point I’m solving a problem and introducing another one.

Anyway yes, the lack of support and the minimal content available is very disapponting

Still learning by trial and error :smiley:

Hey Enter Reality are you sure you’ve ticked “Used with Instanced Static Meshes” in the Usage settings of your pillar material? Without that ticked materials do not show up on instanced static meshes.

Totally forgot about that, and that was exactly the issue :slight_smile:
Thanks!

Too bad ISM doesn’t support LODs properly :confused:

Considering I’m creating very small environments ( corridors ) LODs are not a big issue right now.

One thing I notice in my scene, which is a corridor, an elevator and a upper floor with a skeletal mesh there, if from the lower corridor I look upwards, I can see ( thru stat engine ) that the skeletal mesh is added onto the polycount, which in theory should not be visible, since I can’t actually see the mesh, so I guess occlusion must be put there manually?
Should I use Precomputed visibility volumes to avoid seen asset in the scene?

To solve this I actually tried to use level streaming, but I notice that if I use that while in-game, the S7 freeze for like half a second and then it runs fine again, which I guess it due to the loading of the level ( and unloading of the other one ).

So, visibility volumes or streaming? which one is better for performance?