Transparency with blend mode "masked"

Hello everyone,

I have buy some assets on the markeplace, and the tree materials are in blend mode “masked”…
My problem is that i want the trees to become transparent if they are between the camera and the player, and i don’t how to do it if my material are in “masked”… maybe someone have a solution ?

Thank you :slight_smile:

So, if the trees are between player and camera, then they’re to go transparent / translucent? Is it at a certain distance range with regard to player / camera? I think “masked” is the blend mode used for it. If not that, then one aspect of it is translucency sort priority set to higher than any other object / actor in the level, including other translucent ones. It would probably work in a blueprint using an if statement and the condition being trees are between player and camera…but there’s probably a few other aspects to it for it to function right.

Thank you @presto423 for your help, i’ll try to answer you, however i’m not sure at 100% to understand what you said, so please tell me if you think i dind’t understand your answer. :slight_smile:

→ The problem is that ifi use another blend mode, the mesh will be messed up, and the tree will look like… this :

Thanks for your precious help :slight_smile:

Hi, use Masked Material and use DitherTemporalAA into the opacity mask (so multiply what you currently plug into opacity mask with this DitherTemporalAA). Set Random to 0 and the Alpha Threshold will be the Opacity of the tree. So when you want the tree to vanish, set the Alpha Threshold to 0, else set it to 1, and you can also gradually fade the tree out using a blueprint to drive the Alpha Threshold.


Thank you a lot @chrudimer !
You are a genious, i’m pretty new with materials and this helped me a LOT.

This is perferct, thank you again and have a nice day ! :slight_smile:

Yeah, just dither the opacity based on camera distance. It can look pretty ugly with ghosting but it allows you to keep the material alpha-tested and cheaper.

Thank you also @rosegoldslugs for your help & your time. :slight_smile:
I’ll try to set up all this the best i can !