private IEnumerator RoomMeshLoaded_Coroutine() { yield return(new WaitForSeconds(Constants.Thresholds.ExpectedTimeToLoadRoomMesh)); LayerSwitcher.ChangeMeshLayer(); CentralProcessor.SetMaterials(); }
// Use this for initialization void Awake() { // Enable Hololens commands for starting and stopping texture capture Interactions.EnableVoiceCommand(Constants.Commands.VoiceCommandsEnum.BeginRoomTexture); Interactions.EnableVoiceCommand(Constants.Commands.VoiceCommandsEnum.EndRoomTexture); RoomMeshLoaded += TextureManager_RoomMeshLoaded; TextureCaptureFinished += TextureManager_TextureCaptureFinished; CentralProcessor.UpdateRenderMethodUsed(true); }
public static void UpdateRenderMethodUsed(bool startup = false) { int numFiles = Directory.GetFiles(Constants.Folders.ClippedRoomTextureFolderPath).Length; bool updatedLessThanTextureThreshold = numFiles < Constants.Thresholds.TextureThreshold; if (updatedLessThanTextureThreshold != Constants.Thresholds.LessThanTextureThreshold || startup) { CentralProcessor.SetMaterials(); AttachPrefab(); } Constants.Thresholds.LessThanTextureThreshold = numFiles < Constants.Thresholds.TextureThreshold; }
private void TextureManager_TextureCaptureFinished() { CentralProcessor.GenerateTexturePrefab(); CentralProcessor.UpdateRenderMethodUsed(); }