Skip to main content
←API Reference ←com.nianticspatial.nsdk.playback ←PlaybackDataset

open


Declaration​

@JvmStatic fun open(datasetPath: String): PlaybackDataset?

Summary​

Opens the dataset at datasetPath: a filesystem directory, or asset://<directory> for a
directory in the application APK's assets, e.g. "asset://playback/my_capture" for
src/main/assets/playback/my_capture/.

Returns​

The dataset, or null if it cannot be opened or parsed.

Parameters​

NameTypeSummary
datasetPathString
-

Overload​

suspend fun open(scanId: String, onProgress: (Double) -> Unit): PlaybackDataset

Summary​

Opens a scan's recording through the active com.nianticspatial.nsdk.NSDKSession's
playback cachecom.nianticspatial.nsdk.NSDKSession.playbackCache; see
PlaybackCacheSession.open.


Uses the active session; create and authorize it first. Calling close() on the session
ends an open in flight with PlaybackOpenError.SESSION_ENDED.

Throws​

  • PlaybackOpenException — with PlaybackOpenError.NO_SESSION if no session is active, and otherwise what PlaybackCacheSession.open throws.

Parameters​

NameTypeSummary
scanIdString
-
onProgress(Double) -> Unit
-