Fixed dirty bug, set default resolution for generateTexture to 1