How To Hide a Canvas Renderer?

I am trying to render a script-generated mesh under the UGUI canvas system, and somehow managed to do so by manually setting vertices of a CanvasRenderer (by the way this works weird, I have to make sure the vertices within the list passed to SetVertices remain a particular order, that 4 vertices in a group and a clockwise geometric order… i am not quite sure if i make it right)

anyway, it works!

And now my questions would be how to hide this mesh? I tried to SetActive(false) the container gameobject but the rendered mesh was still visible on the screen…

now the workaround for me is just CanvasRenderer.SetAlpha, but you know…
Thank you for Any Advice.

That’s the correct way to set vertices; the canvas renderer only uses quads so it’s not actually weird with that in mind. SetActive indeed does nothing, so I submitted a bug about that a while ago.

–Eric