()
| 51 | * Clears reconstruction, caches, selections, and view state. |
| 52 | */ |
| 53 | export function resetSession(): void { |
| 54 | // Clear all caches (including ZIP) |
| 55 | clearAllCaches(); |
| 56 | |
| 57 | // Clear reconstruction store |
| 58 | useReconstructionStore.getState().clear(); |
| 59 | useImageMetricsStore.getState().clearSplatPsnr(); |
| 60 | |
| 61 | // Reset transform state |
| 62 | const transformStore = useTransformStore.getState(); |
| 63 | transformStore.resetTransform(); |
| 64 | transformStore.resetSplatTransform(); |
| 65 | |
| 66 | // Reset point picking state |
| 67 | usePointPickingStore.getState().reset(); |
| 68 | |
| 69 | // Clear camera selections and navigation history |
| 70 | const cameraStore = useCameraStore.getState(); |
| 71 | cameraStore.setSelectedImageId(null); |
| 72 | cameraStore.clearFlyTo(); |
| 73 | cameraStore.clearNavigationHistory(); |
| 74 | cameraStore.clearFlyToViewState(); |
| 75 | |
| 76 | // Close any open modals |
| 77 | const uiStore = useUIStore.getState(); |
| 78 | uiStore.closeImageDetail(); |
| 79 | uiStore.closeContextMenu(); |
| 80 | uiStore.closeContextMenuEditor(); |
| 81 | |
| 82 | // Reset view |
| 83 | uiStore.resetView(); |
| 84 | } |
| 85 | |
| 86 | /** |
| 87 | * Reset the 3D view to default camera position. |
nothing calls this directly
no test coverage detected