- Home /
Getting the screen size in world units
I've seen a bunch of variations on this question, but nothing that quite matches what I'm thinking about.
I'm doing a little CRT simulation and I wanted to start scrolling the text if the textMesh goes off the screen. The easiest way to do this seemed to be checking like this:
if(text.renderer.bounds.extents.y > SCREEN_HEIGHT_IN_WORLD) scrollText();
The issue is getting the screen height in world space (And, of course, this supposes that the text starts at the upper left, which is fine for me). I can get it in pixels, but not units.
Any thoughts? I could draw a collider around the frustrum at runtime, but that seems like a silly solution.
Your answer
![](https://koobas.hobune.stream/wayback/20220613185931im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
World Space UI Scale To Fit Screen At DIfferent Aspect Ratios 1 Answer
How do I make a UI element in world space cover a game object in the scene? 0 Answers
Setup Unity enviroment (world space) for Pixel Perfect movement ? 1 Answer
Are there any world bounds in Android? 0 Answers
Pixel Perfect Camera - Change PPU by script depending on screen width/height 0 Answers