Skip to main content
Participant
July 2, 2025
Solved

How to set alphaMode on custom material?

  • July 2, 2025
  • 1 reply
  • 221 views
I only see the alphaMode in the SceneMaterial constructor, but not in the SceneMaterial.custom function? Not is there a settable property for this?

 I want objects with some of my custom materials to use the TRANSLUCENT_POST option.

    This topic has been closed for replies.
    Best answer by davs

    Hi! AlphaMode is effectively specifying both a blend mode and a sort order.

    When using a custom SceneMaterial, you cannot specify the AlphaMode but rather you can control SortOrder (SceneMaterial.setSortOrder()) and BlendMode (SceneMaterial.setBlendMode()) individually. For TRANSLUCENT_POST, you will probably need to use BlendMode.TRANSLUCENT and SortOrder.POSTPROCESS.

     

    Hope this helps!

    1 reply

    davsAnswer
    Meta Employee
    July 3, 2025

    Hi! AlphaMode is effectively specifying both a blend mode and a sort order.

    When using a custom SceneMaterial, you cannot specify the AlphaMode but rather you can control SortOrder (SceneMaterial.setSortOrder()) and BlendMode (SceneMaterial.setBlendMode()) individually. For TRANSLUCENT_POST, you will probably need to use BlendMode.TRANSLUCENT and SortOrder.POSTPROCESS.

     

    Hope this helps!