Texture init now only creates required number of mipmap levels.

Per discussion on mailing list, change to fix problems with latest nvidia drivers on Linux, and create only the required number of mipmap levels for a given texture size.