Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We’re making changes to the Unity Runtime Fee pricing policy that we announced on September 12th. Access our latest thread for more information!
    Dismiss Notice
  3. Dismiss Notice

Masking object

Discussion in '2D' started by CinkoNaap, Dec 27, 2013.

  1. CinkoNaap

    CinkoNaap

    Joined:
    Oct 2, 2011
    Posts:
    9
    Hey,

    I am wondering how can I achive a mask clip effect in Unity3D.

    What i want to achive is to set for an object ( which has a 2d renderer component ) it's mask object, so only pixles covered by mask are rendered ( and mask itself is invisible ).

    For example I have an game object called "A" with SpriteRenderer component, and game object "B" with SpriteRenderer component.
    If I set A.mask = B, I want B graphics to be invisible, and A pixels only visible if they are covered by B.