Package-level declarations
Types
Link copied to clipboard
class ARCore(val onSessionCreated: (session: Session) -> Unit, val onSessionResumed: (session: Session) -> Unit, val onSessionPaused: (session: Session) -> Unit, val onArSessionFailed: (Exception) -> Unit, val onSessionConfigChanged: (session: Session, config: Config) -> Unit)
Manages an ARCore Session using the Android Lifecycle API. Before starting a Session, this class requests installation of Google Play Services for AR if it's not installed or not up to date and asks the user for required permissions if necessary.
Link copied to clipboard
Link copied to clipboard
open class ARSceneView @JvmOverloads constructor(context: Context, attrs: AttributeSet? = null, defStyleAttr: Int = 0, defStyleRes: Int = 0, sharedActivity: ComponentActivity? = null, sharedLifecycle: Lifecycle? = null, sharedEngine: Engine? = null, sharedModelLoader: ModelLoader? = null, sharedMaterialLoader: MaterialLoader? = null, sharedEnvironmentLoader: EnvironmentLoader? = null, sharedScene: Scene? = null, sharedView: View? = null, sharedRenderer: Renderer? = null, sharedCameraNode: ARCameraNode? = null, sharedMainLightNode: LightNode? = null, sharedEnvironment: Environment? = null, isOpaque: Boolean = true, sharedCollisionSystem: CollisionSystem? = null, sharedCameraStream: ARCameraStream? = null, val sessionFeatures: Set<Session.Feature> = setOf(), val sessionCameraConfig: (Session) -> CameraConfig? = null, sessionConfiguration: (session: Session, Config) -> Unit? = null, viewNodeWindowManager: ViewNode2.WindowManager? = null, var onSessionCreated: (session: Session) -> Unit? = null, var onSessionResumed: (session: Session) -> Unit? = null, var onSessionPaused: (session: Session) -> Unit? = null, var onSessionFailed: (Exception) -> Unit? = null, var onTrackingFailureChanged: (trackingFailureReason: TrackingFailureReason?) -> Unit? = null, onGestureListener: GestureDetector.OnGestureListener? = null, onTouchEvent: (e: MotionEvent, hitResult: HitResult?) -> Boolean? = null, var onSessionUpdated: (session: Session, frame: Frame) -> Unit? = null) : SceneView
A SurfaceView that integrates with ARCore and renders a scene
Link copied to clipboard
Link copied to clipboard
Renders a single ARCore Plane.
Link copied to clipboard
class Scene
= SceneView/ARSceneView is a Scene (NodeParent) that can contain
Properties
Functions
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun ARScene(modifier: Modifier = Modifier, engine: Engine = rememberEngine(), modelLoader: ModelLoader = rememberModelLoader(engine), materialLoader: MaterialLoader = rememberMaterialLoader(engine), environmentLoader: EnvironmentLoader = rememberEnvironmentLoader(engine), sessionFeatures: Set<Session.Feature> = setOf(), sessionCameraConfig: (Session) -> CameraConfig? = null, sessionConfiguration: (session: Session, Config) -> Unit? = null, planeRenderer: Boolean = true, cameraStream: ARCameraStream? = rememberARCameraStream(materialLoader), view: View = rememberView(engine), isOpaque: Boolean = true, renderer: Renderer = rememberRenderer(engine), scene: Scene = rememberScene(engine), environment: Environment = rememberAREnvironment(engine), mainLightNode: LightNode? = rememberMainLightNode(engine), cameraNode: ARCameraNode = rememberARCameraNode(engine), childNodes: List<Node> = rememberNodes(), collisionSystem: CollisionSystem = rememberCollisionSystem(view), viewNodeWindowManager: ViewNode2.WindowManager? = null, onSessionCreated: (session: Session) -> Unit? = null, onSessionResumed: (session: Session) -> Unit? = null, onSessionPaused: (session: Session) -> Unit? = null, onSessionFailed: (Exception) -> Unit? = null, onSessionUpdated: (session: Session, frame: Frame) -> Unit? = null, onTrackingFailureChanged: (trackingFailureReason: TrackingFailureReason?) -> Unit? = null, onGestureListener: GestureDetector.OnGestureListener? = rememberOnGestureListener(), onTouchEvent: (e: MotionEvent, hitResult: HitResult?) -> Boolean? = null, activity: ComponentActivity? = LocalContext.current as? ComponentActivity, lifecycle: Lifecycle = LocalLifecycleOwner.current.lifecycle, onViewUpdated: ARSceneView.() -> Unit? = null, onViewCreated: ARSceneView.() -> Unit? = null)
Link copied to clipboard
Link copied to clipboard
fun rememberARCameraNode(engine: Engine, creator: () -> ARCameraNode = {
ARSceneView.createARCameraNode(engine)
}): ARCameraNode
Link copied to clipboard
fun rememberARCameraStream(materialLoader: MaterialLoader, creator: () -> ARCameraStream = {
ARSceneView.createARCameraStream(materialLoader)
}): ARCameraStream
Link copied to clipboard