PerceptionSpace


class PerceptionSpace : BaseScenePose


PerceptionSpace is an ScenePose used to track the origin of the space used by ARCore for Jetpack XR APIs.

Summary

Public functions

ScenePose

Returns a ScenePose from a Pose relative to this PerceptionSpace.

Inherited functions

From androidx.xr.scenecore.BaseScenePose
open suspend HitTestResult?
hitTest(origin: Vector3, direction: Vector3)

Perform a hit test from the specified origin in the specified direction into the Scene.

open suspend HitTestResult?
hitTest(origin: Vector3, direction: Vector3, hitTestFilter: Int)

Creates a hit test from the specified origin in the specified direction into the scene.

open Vector3
transformDirectionTo(direction: Vector3, destination: ScenePose)

Transforms a direction from this ScenePose's local space to the destination ScenePose's local space.

open Pose
transformPoseTo(pose: Pose, destination: ScenePose)

Returns a Pose relative to this ScenePose, transformed into a Pose relative to the destination.

open Vector3
transformPositionTo(position: Vector3, destination: ScenePose)

Transforms a position from this ScenePose's local space to the destination ScenePose's local space.

open Vector3
transformVectorTo(vector: Vector3, destination: ScenePose)

Transforms a vector from this ScenePose's local space to the destination ScenePose's local space.

Inherited properties

From androidx.xr.scenecore.BaseScenePose
open Pose

The current Pose relative to the activity space root.

Public functions

getScenePoseFromPerceptionPose

Added in 1.0.0-alpha12
fun getScenePoseFromPerceptionPose(pose: Pose): ScenePose

Returns a ScenePose from a Pose relative to this PerceptionSpace.

Parameters
pose: Pose

a Pose relative to the perceptionSpace.

Returns
ScenePose

a ScenePose containing the position in the PerceptionSpace.