Search Unity

Selectively Mask UI Elements?

Discussion in 'UGUI & TextMesh Pro' started by kaffiene, May 23, 2017.

  1. kaffiene

    kaffiene

    Joined:
    May 26, 2013
    Posts:
    21
    Is there a way to selectively mask UI elements? I have a table that I'm drawing contents inside. Sometimes these draw over the bounds of the table and the mask does a great job clipping these elements, but I also draw scale 'tick marks' outside of the bounds of the table and I want these elements to remain and not be clipped. I was hoping that possibly it was possible to selectively clip UI elements - perhaps by layer or tag?

    Thanks in advance

    Peter.
     
  2. kaffiene

    kaffiene

    Joined:
    May 26, 2013
    Posts:
    21
    I've added an image to explain what's going on. You can see the before and after images (there's a freehand drawn yellow line on the before image to show where the edge of the panel is). The after image has clipped the boxes going over the edge - which is what I wanted, but also clipped the tick marks and text around the edge - which wasn't what was wanted. clip.png