- Home /
Screen Space - Camera to Screen Space - Overlay switch issue
Hey guys,
I'm having problems with switching between Screen Space - Camera and Screen Space - Overlay. I have a UI consisting of a Canvas, one empty child and 6 RectTransforms (containers) with UI stuff in them.
for special occasions I need to change the rendermode of the canvas for several of those containers.
What happens is: - I programmatically change the canvas from Overlay to Camera, during OnEnable of container A. Works fine - I then revert the canvas settings back to Overlay in OnDisable and Enable another Container B. GONE, it's not visible.
if i start with container B it's visible, but the change through Screen Space - Camera once seems to be changing the canvas in ways that never get reverted. I moved container B -5 in z after the rendermode changes and it showed up again.
How do I get the canvas back to starting configuration? Canvas.ForceUpdateCanvases doesn't do anything, fiddling with the canvas setting as well.
Your answer
Follow this Question
Related Questions
Particle System not showing over "Screen Space - Overlay" UI Canvas 0 Answers
Missing Camera for Canvas (Screen Space - Overlay)? 0 Answers
UI Mask doesnt work with Screen Space - Camera canvas? 2 Answers
Strange Canvas behaviour at Screen Space - Camera mode? 0 Answers
Canvas screenpspace overlay for a particular camera 0 Answers