Masking Child with Parent Drawn On Top


In the example image, it would be ideal to create 1 simple paper texture to mask instead of making 9 slice elements for the top left Ikko Ikki part, under it where the Vassals: , Allies: etc part is, the hover yellow mid part, and the very top title bar.

It does not appear to be possible to set an Image to mask off the underlying texture and draw the border on top of it. If you click “Show Graphic” on the parent mask it does nothing at all. It is also insanely jagged and wouldn’t pass for lots of UI elements. Is it also extremely cpu intensive to use it on 20+ elements on screen at once?

I have a feeling I’ll just be creating all the 9 slice elements I need one by one.

If I understand you correctly, you want to mask a single element (a paper background) by many masks (title frames, a frame with "Vassals: ", etc…). As far as I know, there is no good way to do so in Unity. It may be achieved by custom shaders but I don’t think is a good idea from both performance and productivity point of view. It would be much easier to make 9 slices :slight_smile: