private async Task StopRealsensePipeline() { if (!IsRealsensePipelineOn) { RealsenseState = "Pipeline is not on"; return; } RealsenseControl.StopRealsensePipeline(); IsRealsensePipelineOn = false; await UpdateRGBPoseTask; await UpdateRealTimePointCloudTask; }
private void StopRealsensePipeline() { if (!IsRealsensePipelineOn) { RealsenseState = "Pipeline is not on"; return; } RealsenseControl.StopRealsensePipeline(); IsRealsensePipelineOn = false; UpdateRGBPoseTask.Wait(); UpdateRealTimePointCloudTask.Wait(); }