Add render mode switch function.