ARSession

class ARSession(context: Context, features: Set<Session.Feature> = setOf(), val onResumed: (session: Session) -> Unit, val onPaused: (session: Session) -> Unit, val onConfigChanged: (session: Session, config: Config) -> Unit) : Session

Constructors

Link copied to clipboard
constructor(context: Context, features: Set<Session.Feature> = setOf(), onResumed: (session: Session) -> Unit, onPaused: (session: Session) -> Unit, onConfigChanged: (session: Session, config: Config) -> Unit)

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
var frame: Frame?

The most recent ARCore Frame if it is available

Link copied to clipboard
Link copied to clipboard
val onConfigChanged: (session: Session, config: Config) -> Unit
Link copied to clipboard
val onPaused: (session: Session) -> Unit
Link copied to clipboard
val onResumed: (session: Session) -> Unit

Functions

Link copied to clipboard
fun Session.canHostCloudAnchor(cameraNode: ARCameraNode): Boolean
Link copied to clipboard
open fun checkVpsAvailabilityAsync(p0: Double, p1: Double, @Nullable p2: Consumer<VpsAvailability>?): VpsAvailabilityFuture
Link copied to clipboard
open fun close()
Link copied to clipboard
open override fun configure(config: Config)
Link copied to clipboard
fun Session.configure(config: Config): Nothing?

fun Session.configure(config: (Config) -> Unit)

Define the session config used by ARCore

Link copied to clipboard
open fun createAnchor(p0: Pose): Anchor
Link copied to clipboard
open fun estimateFeatureMapQualityForHosting(p0: Pose): Session.FeatureMapQuality
Link copied to clipboard
Link copied to clipboard
open fun <T : Trackable> getAllTrackables(p0: Class<T>): MutableCollection<T>
Link copied to clipboard
open fun getCameraConfig(): CameraConfig
Link copied to clipboard
open fun getConfig(): Config
open fun getConfig(p0: Config)
Link copied to clipboard
fun Session.getConfig(): Config
Link copied to clipboard
open fun getEarth(): Earth?
Link copied to clipboard
open fun getPlaybackStatus(): PlaybackStatus
Link copied to clipboard
open fun getRecordingStatus(): RecordingStatus
Link copied to clipboard
open fun getSharedCamera(): SharedCamera
Link copied to clipboard
open fun getSupportedCameraConfigs(p0: CameraConfigFilter): MutableList<CameraConfig>
Link copied to clipboard
open fun hostCloudAnchor(p0: Anchor): Anchor
Link copied to clipboard
open fun hostCloudAnchorAsync(p0: Anchor, p1: Int, @Nullable p2: BiConsumer<String, Anchor.CloudAnchorState>?): HostCloudAnchorFuture
Link copied to clipboard
open fun hostCloudAnchorWithTtl(p0: Anchor, p1: Int): Anchor
Link copied to clipboard
open fun isDepthModeSupported(p0: Config.DepthMode): Boolean
Link copied to clipboard
open fun isGeospatialModeSupported(p0: Config.GeospatialMode): Boolean
Link copied to clipboard
open fun isImageStabilizationModeSupported(p0: Config.ImageStabilizationMode): Boolean
Link copied to clipboard
open fun isSemanticModeSupported(p0: Config.SemanticMode): Boolean
Link copied to clipboard
open fun isSupported(p0: Config): Boolean
Link copied to clipboard
open override fun pause()
Link copied to clipboard
open fun resolveCloudAnchor(p0: String): Anchor
Link copied to clipboard
open fun resolveCloudAnchorAsync(p0: String, @Nullable p1: BiConsumer<Anchor, Anchor.CloudAnchorState>?): ResolveCloudAnchorFuture
Link copied to clipboard
open override fun resume()
Link copied to clipboard
open fun setCameraConfig(p0: CameraConfig)
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open override fun setDisplayGeometry(rotation: Int, widthPx: Int, heightPx: Int)
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun startRecording(p0: RecordingConfig)
Link copied to clipboard
open fun stopRecording()
Link copied to clipboard
open fun update(): Frame
Link copied to clipboard
fun updateOrNull(): Frame?

Updates the state of the ARCore system. This includes: receiving a new camera frame, updating the location of the device, updating the location of tracking anchors, updating detected planes, etc.