public void SelectProjector(int projectorIndex, bool animateIndex) { if (projectorCount <= projectorIndex) { return; } ProjectionMesh mesh = null; if (selectedMesh >= 0 && selectedMesh <= 7) { GetCurrentProjectionCamera().DeactivateSelection(); } selectedMesh = projectorIndex; mesh = GetCurrentProjectionCamera(); calibrationManager.currentProjectorText.text = (projectorIndex + 1).ToString(); if (animateIndex) { mesh.ShowProjectorIndex(); } //check to see if in blend, white balance or help mode if (calibrationManager.state == CalibrationManager.MenuState.BLEND || calibrationManager.state == CalibrationManager.MenuState.WHITE_BALANCE || calibrationManager.state == CalibrationManager.MenuState.HELP) { //cache the current mode CalibrationManager.MenuState state = calibrationManager.state; //reset selections SetEditMode(ProjectionMesh.MeshEditMode.NONE); //reapply current mode calibrationManager.SetButtonState(state); } else { //use last used edit mode SetEditMode(mesh.editMode); } //update UI values by applying only to sliders calibrationManager.topRangeSlider.value = mesh.topFadeRange; calibrationManager.topChokeSlider.value = mesh.topFadeChoke; calibrationManager.bottomRangeSlider.value = mesh.bottomFadeRange; calibrationManager.bottomChokeSlider.value = mesh.bottomFadeChoke; calibrationManager.leftRangeSlider.value = mesh.leftFadeRange; calibrationManager.leftChokeSlider.value = mesh.leftFadeChoke; calibrationManager.rightRangeSlider.value = mesh.rightFadeRange; calibrationManager.rightChokeSlider.value = mesh.rightFadeChoke; calibrationManager.redSlider.value = mesh.tint.r * 255; calibrationManager.greenSlider.value = mesh.tint.g * 255; calibrationManager.blueSlider.value = mesh.tint.b * 255; }