IPhone Texure Dimensions

As I understand it, my textures have to be power-of-two and square if I want to use texture compression, unless I am using the textures as GUITextures. On this subject, I have two follow up questions.

  1. When the warning says I have to use them as GUITextures, does that exclude textures which are used with GUI.DrawTexture, GUI.DrawButton, etc? It sounds as though it does, but I wondered if it’s a legacy warning.

  2. If I choose not to use compressed textures, what limitations (if any) still remain? The square limitation doesn’t, but do textures for GUI.Button and GUI.DrawTexture still need to be Power-of-two dimensions or is any old size ok?

I’m essentially working on a game which will be all GUI. So there will be no 3D scene. I would much prefer to use Unity’s new GUI rather than the legacy GUITexture stuff.

Textures have to be power-of-two and square if you want compression, at all. The warning is a legacy from Unity 2.1 and doesn’t apply to the iPhone.

It’s not a good idea to use OnGUI on the iPhone, except for menus where performance doesn’t matter. Use something like SpriteManager2 instead.

–Eric

  1. The requirement holds for all textures, including gui actually

  2. any size is fine

Thanks guys. Since it doesn’t apply to GuiTextures even, that makes that decision easy.

I realize that OnGUI isn’t very fast on IPhone/IPad, but performance isn’t really an issue. There’s no 3D scene, and precious few sprites, most of which don’t move.

Good habits should start early though :slight_smile:

I’ve never used an OnGui thing at all, in fact, I’d have to find a tut on how :slight_smile: