class Config


Defines a configuration state of all available features to be set at runtime.

An instance of this class should be passed to Session.configure to set the current configuration. Use Config.copy on Session.config to modify a copy of the existing configuration to pass to Session.configure.

Summary

Nested types

abstract class Config.ConfigMode

Describes a specific value used to set the configuration via Session.configure.

Public constructors

Config(
    planeTracking: PlaneTrackingMode,
    handTracking: HandTrackingMode,
    deviceTracking: DeviceTrackingMode,
    depthEstimation: DepthEstimationMode,
    anchorPersistence: AnchorPersistenceMode,
    faceTracking: FaceTrackingMode,
    geospatial: GeospatialMode,
    augmentedObjectCategories: Set<AugmentedObjectCategory>
)

Defines a configuration state of all available features to be set at runtime.

Public functions

Config
copy(
    planeTracking: PlaneTrackingMode,
    handTracking: HandTrackingMode,
    deviceTracking: DeviceTrackingMode,
    depthEstimation: DepthEstimationMode,
    anchorPersistence: AnchorPersistenceMode
)
open operator Boolean
equals(other: Any?)
open Int

Public properties

AnchorPersistenceMode

Feature that allows anchors to be persisted through sessions.

Set<AugmentedObjectCategory>

Feature that allows tracking of recognizable objects in the environment.

DepthEstimationMode

Feature that allows more accurate information about scene depth and meshes.

DeviceTrackingMode

Feature that allows tracking of the AR device.

FaceTrackingMode
GeospatialMode

Feature that allows geospatial localization and tracking.

HandTrackingMode

Feature that allows tracking of the user's hands and hand joints.

PlaneTrackingMode

Feature that allows tracking of and provides information about scene planes.

Public constructors

Config

Added in 1.0.0-alpha13
Config(
    planeTracking: PlaneTrackingMode = PlaneTrackingMode.DISABLED,
    handTracking: HandTrackingMode = HandTrackingMode.DISABLED,
    deviceTracking: DeviceTrackingMode = DeviceTrackingMode.DISABLED,
    depthEstimation: DepthEstimationMode = DepthEstimationMode.DISABLED,
    anchorPersistence: AnchorPersistenceMode = AnchorPersistenceMode.DISABLED,
    faceTracking: FaceTrackingMode = FaceTrackingMode.DISABLED,
    geospatial: GeospatialMode = GeospatialMode.DISABLED,
    augmentedObjectCategories: Set<AugmentedObjectCategory> = setOf()
)

Defines a configuration state of all available features to be set at runtime.

An instance of this class should be passed to Session.configure to set the current configuration. Use Config.copy on Session.config to modify a copy of the existing configuration to pass to Session.configure.

Parameters
planeTracking: PlaneTrackingMode = PlaneTrackingMode.DISABLED

Feature that allows tracking of and provides information about scene planes. See PlaneTrackingMode.

handTracking: HandTrackingMode = HandTrackingMode.DISABLED

Feature that allows tracking of the user's hands and hand joints. See HandTrackingMode.

deviceTracking: DeviceTrackingMode = DeviceTrackingMode.DISABLED

Feature that allows tracking of the AR device. See DeviceTrackingMode.

depthEstimation: DepthEstimationMode = DepthEstimationMode.DISABLED

Feature that allows more accurate information about scene depth and meshes. See DepthEstimationMode.

anchorPersistence: AnchorPersistenceMode = AnchorPersistenceMode.DISABLED

Feature that allows anchors to be persisted through sessions. See AnchorPersistenceMode.

faceTracking: FaceTrackingMode = FaceTrackingMode.DISABLED

Feature that allows tracking of human faces. See FaceTrackingMode.

geospatial: GeospatialMode = GeospatialMode.DISABLED

Feature that allows geospatial localization and tracking. See GeospatialMode.

augmentedObjectCategories: Set<AugmentedObjectCategory> = setOf()

Feature that allows tracking of recognizable objects in the environment. See AugmentedObjectCategory.

Public functions

copy

Added in 1.0.0-alpha13
fun copy(
    planeTracking: PlaneTrackingMode = this.planeTracking,
    handTracking: HandTrackingMode = this.handTracking,
    deviceTracking: DeviceTrackingMode = this.deviceTracking,
    depthEstimation: DepthEstimationMode = this.depthEstimation,
    anchorPersistence: AnchorPersistenceMode = this.anchorPersistence
): Config

equals

open operator fun equals(other: Any?): Boolean

hashCode

open fun hashCode(): Int

Public properties

anchorPersistence

Added in 1.0.0-alpha13
val anchorPersistenceAnchorPersistenceMode

Feature that allows anchors to be persisted through sessions. See androidx.xr.runtime.AnchorPersistenceMode.

augmentedObjectCategories

Added in 1.0.0-alpha13
val augmentedObjectCategoriesSet<AugmentedObjectCategory>

Feature that allows tracking of recognizable objects in the environment. See androidx.xr.runtime.AugmentedObjectCategory.

depthEstimation

Added in 1.0.0-alpha13
val depthEstimationDepthEstimationMode

Feature that allows more accurate information about scene depth and meshes. See androidx.xr.runtime.DepthEstimationMode.

deviceTracking

Added in 1.0.0-alpha13
val deviceTrackingDeviceTrackingMode

Feature that allows tracking of the AR device. See androidx.xr.runtime.DeviceTrackingMode.

faceTracking

Added in 1.0.0-alpha13
val faceTrackingFaceTrackingMode

geospatial

Added in 1.0.0-alpha13
val geospatialGeospatialMode

Feature that allows geospatial localization and tracking. See androidx.xr.runtime.GeospatialMode.

handTracking

Added in 1.0.0-alpha13
val handTrackingHandTrackingMode

Feature that allows tracking of the user's hands and hand joints. See androidx.xr.runtime.HandTrackingMode.

planeTracking

Added in 1.0.0-alpha13
val planeTrackingPlaneTrackingMode

Feature that allows tracking of and provides information about scene planes. See androidx.xr.runtime.PlaneTrackingMode.