Are all mobile devices supposed to support custom stencils?

Hello,

In the last release notes (https://www.unrealengine.com/blog/unreal-engine-4-15-released) , it is said that mobile devices now support custom stencils. I made one for my game and it works on my PC but not on my phone (LG G4). Is this a bug or is it normal?

Thank you!

Hi, could you share a screenshot of PP material that uses CustomStencil ? And make sure that MobileHDR is enabled in your project settings.

Hello,
Sure thing! I was going to take screenshots but it’s a pretty big blueprint, it wouldn’t have been super readable. I got the material from here: Multi-color Outline Post Process - Tom Looman

I haven’t modified it so you can try it as-is.
In my project settings, I have enabled Mobile HDR and I have also set ‘Custom Depth-Stencil Pass’ to ‘Enabled with Stencil’. I have a PostProcessVolume around my play area with the PP_OutlineColored_Inst in the Post Process Materials array, with an effect value of 1.0.

Here is how I turn the stencil on or off for my objects:

Thank you!

Sorry for the delay. Does this outline works in editor when you switch to mobile preview mode? (MainToolbar - > Settings → Preview Rendering Level → Mobile → Default Mobile)

Also could you attach here log output when you start project on that device? To get filtered log from device you can enable Device Output Log window in editor. (Editor Preferences → Experiemental → Device Output Log) it will appear in MainMenu - > Windows.

No problem. The stencil doesn’t show up on PC when in mobile preview mode.

I have attached the [log file][1]. Note that there might be some errors related to another bug.

Thanks

[1]:

I have tried to reproduce it but I couldn’t. I have, however, found a way to fix it in my game when trying to create the test project. If I set the blend weight of my camera to a value other than 1, the stencil appears.

My camera is a Blueprint inheriting from a C++ class AMyCamera that itself is derived from ACameraActor. Both the C++ class and Blueprint don’t do anything special, only display text on specific events.

I do not understand why changing the blending weight affects the stencil in my project but it works. It’s especially weird since it only does it on mobile/mobile preview.

Thanks for your help!

I have downloaded that material and it works in mobile preview for me. However I don’t do dynamic modifications of stencil values as in your BP. Could you attach here a small project that repro this?

Hi, I don’t use any lightning feature on my game, only the stencil, Is there a way to only activate HDR for that or something like that?