Full Screen Quad

What’s the best way to create a full screen quad, that will be resolution independent? I basically want to create a background that will scale with each different mobile device (so it will have to be optimized for the iPhone 3GS upwards).

I guess creating a mesh based on the viewport conversion into world space? Then calculating the uv’s and texturing it?

Any insight would be awesome! :slight_smile:

Use a GUITexture, with the x/y scale as 1.0 and the x/y position as 0.5, and 0 for all pixel inset values. Then use another camera to display content on top of that (with clear flags set to depth only).

–Eric

Won’t using any part of Unity’s GUI reduce my frame rate exponentially? I thought this is why most users stay clear of Unity’s GUI system, and use EZGUI or NGUI?

Cheers, Alex.

No, I’m talking about a GUITexture object, not OnGUI code. (But even that doesn’t reduce the frame rate “exponentially”, just somewhat, and only if you have a complex GUI.)

–Eric

Ok thanks Eric. Yeah, sorry exponentially was definitely an overstatement. I’ve just been told time and time again, to steer way clear of OnGUI code, especially with regards to mobile development.

Thanks again.