A dynamically spawned CaptureComponent2D SceneCapture Actor does not apply the flags which are set in the details panel

I try to change the flags in the details panel of the CaptureComponent2D:

http://puu.sh/gVLuS/467f66ecb2.png

Then I spawn the SceneCapture Actor in Event Begin Play of the PlayerController and unfortunately the default values are used, so I see static meshes, fog, skeletal meshes and so on. But if I change one of these values during runtime (clicking on the SceneCapture2D Actor and change one flag) they all get applied.

If I just place the SceneCapture Actor manually in the Editor all flags are applied correctly.

Hi John,

How exactly are you setting up the Target Texture at runtime while spawning the SceneCapture2D off of the Event Begin Play?

We found that setting it in the Details panel after playing was the only successful way but that isn’t really a useful implementation in a game. However once spawned, toggling the flags worked correctly for us in 4.7.3.

Also, one of our Rendering Engineers is wondering why you are spawning the SceneCapture this way instead of adding it as a component to the blueprint or adding it to the level directly?

I don’t set up the target texture at runtime, the target texture I have defined in the SceneCapture2D CaptureComponent2D Component (it’s always the same).

Toggling the flags on runtime works, yes. But before you toggle any of the flags at runtime always the default values are used and NOT the values you set inside of the spawned Actor.

I should add it as a component to what? I don’t wan’t to add it manually in the Editor because that’s just an extra step of work. It should just work with every level without having me to place it there. It’s for a minimap, so I need it in every level.

We haven’t been able to reproduce this yet. I have included a small test project that we’ve create which has a basic mini-map setup using a SceneCapture2D. Could you recreate the error that you are seeing in this testbed and then upload it here? It’s using version 4.7.3 of the editor.

Test Project

I am not able to reproduce it in your project, I wonder why. Actually, I can’t even get the atmospheric fog to get rendered on the texture. Even if I add so much fog that I can’t see more far than 1 meter and I place the SceneCapture2D 5000 Units in the Air pointing down, I still don’t see any fog on the texture. I only clearly see the meshes. Your project is quite strange, do you have an idea why the fog is not rendered on the texture?

It’s a current limitation of UMG. If you put the ‘NewMaterial’ onto a static mesh it will show the fog correctly.

Ok you are right, what is this “limitation” of UMG?

If I put the material on a static mesh I can see the fog.

I was able to reproduce it in your project and will upload it shortly.

Here it is:

Hi John,

Thanks for re-uploading that project. I have created JIRA UE-13368 for the issue and our developers will be investigating it further. We’ll post back here with updates as we have them.

Also, the UMG limitation that I mentioned is that it doesn’t correctly display Atmospheric Fog at the moment.

Just a side note, it is not recommended to use Atmospheric Fog and Exponential Height Fog in the same level. They do not interact well with one another.

Cheers,

TJ

Hi TJ, are there any updates on this?

Hi John,

This has been fixed and is working properly for me in the 4.8.1 build. If you are still seeing this not working in your project, could you try testing it in a new project and let me know your results?