Added texture freeing for tempTexture2.