Fix resizeTexture for scaling up and other TEXTURE-related fixes