add support for non power of 2 textures