JxrPlatformAdapter


public interface JxrPlatformAdapter


Interface for SceneCore Platform operations. This is not intended to be used by Applications.

Summary

Nested types

Interface for a SceneCore ActivityPanel entity.

Interface for a SceneCore ActivityPose

Interface for a SceneCore activity space.

Interface for a listener which receives changes to the bounds of the primary Activity.

Interface for Anchor entity.

Interface for listening to Anchor state changes.

Specifies the current persistence state of the Anchor.

Interface for listening to Anchor persist state changes.

Specifies the current tracking state of the Anchor.

Interface for an AnchorPlacement.

Interface for a SceneCore AudioTrackExtensionsWrapper

Interface for a SceneCore camera view ActivityPose.

The angles (in radians) representing the sides of the view frustum.

Base interface for all components.

The dimensions of a UI element in meters.

Interface for a SceneCore Entity

Interface for an EXR resource.

Interface for a SceneCore [GltfEntity].

Interface for a glTF resource.

Interface for a SceneCore head ActivityPose.

InputEvent for SceneCore Platform.

Info about the hit result of the ray.

Interface for Input listener.

Component to enable input interactions.

Interface for a SceneCore Entity that only logs the pose.

Interface for a SceneCore MediaPlayerExtensionsWrapper

Component to enable a high level user movement affordance.

MoveEvent for SceneCore Platform.

Interface for MoveEvent listener.

Interface for a SceneCore Panel entity

Interface for the perception space ActivityPose.

The dimensions of a UI element in pixels.

Semantic plane types.

Type of plane based on orientation i.e. Horizontal or Vertical.

Represents a SceneCore PointSourceAttributes

Component to enable pointer capture.

Functional interface for receiving updates about the state of pointer capture.

Ray in 3D Cartesian space.

Component to enable resize semantics.

ResizeEvent for SceneCore Platform.

Interface for ResizeEvent listener.

Interface for a SceneCore resource.

Represents a SceneCore SoundFieldAttributes

Interface for a SceneCore SoundPoolExtensionsWrapper.

Spatial Capabilities for SceneCore Platform.

Interface for updating the background image/geometry and passthrough settings.

Result values for calls to SpatialEnvironment.setPassthroughOpacityPreference

Result values for calls to SpatialEnvironment.setSpatialEnvironmentPreference

A class that represents the user's preferred spatial environment.

Contains the constants used to spatialize audio in SceneCore.

Interface for a surface which images can be rendered into.

Interface for a system-controlled SceneCore Entity that defines its own coordinate space.

Interface for a listener which receives changes to the underlying space.

Public methods

abstract void

Adds the given Consumer as a listener to be invoked when this Session's current SpatialCapabilities change. accept will be invoked on the given Executor.

abstract @NonNull JxrPlatformAdapter.ActivityPanelEntity
createActivityPanelEntity(
    @NonNull Pose pose,
    @NonNull JxrPlatformAdapter.PixelDimensions windowBoundsPx,
    @NonNull String name,
    @NonNull Activity hostActivity,
    @NonNull JxrPlatformAdapter.Entity parent
)

Factory function to create ActivityPanel to launch/move activity into.

abstract @NonNull JxrPlatformAdapter.AnchorEntity

A factory function to create an Anchor entity from a androidx.xr.arcore.Anchor.

abstract @NonNull JxrPlatformAdapter.AnchorEntity

A factory function to create an Anchor entity.

abstract @NonNull JxrPlatformAdapter.AnchorPlacement

Creates an instance of an AnchorPlacement object.

abstract @NonNull JxrPlatformAdapter.Entity
createEntity(
    @NonNull Pose pose,
    @NonNull String name,
    @NonNull JxrPlatformAdapter.Entity parent
)

A factory function to create a content-less entity.

abstract @NonNull JxrPlatformAdapter.GltfEntity

A factory function to create a SceneCore GltfEntity.

abstract @NonNull JxrPlatformAdapter.InteractableComponent

Create an Interactable component.

abstract @NonNull JxrPlatformAdapter.LoggingEntity

A function to create a SceneCore Entity

abstract @NonNull JxrPlatformAdapter.MovableComponent
createMovableComponent(
    boolean systemMovable,
    boolean scaleInZ,
    @NonNull Set<JxrPlatformAdapter.AnchorPlacement> anchorPlacement,
    boolean shouldDisposeParentAnchor
)

Create an instance of [MovableComponent].

abstract @NonNull JxrPlatformAdapter.PanelEntity
createPanelEntity(
    @NonNull Pose pose,
    @NonNull View view,
    @NonNull JxrPlatformAdapter.PixelDimensions surfaceDimensionsPx,
    @NonNull JxrPlatformAdapter.Dimensions dimensions,
    @NonNull String name,
    @NonNull Context context,
    @NonNull JxrPlatformAdapter.Entity parent
)

A factory function to create a platform PanelEntity.

abstract @NonNull JxrPlatformAdapter.AnchorEntity
createPersistedAnchorEntity(
    @NonNull UUID uuid,
    @NonNull Duration searchTimeout
)

A factory function to recreate an Anchor entity which was persisted in a previous session.

abstract @NonNull JxrPlatformAdapter.PointerCaptureComponent

Create an instance of PointerCaptureComponent.

abstract @NonNull JxrPlatformAdapter.ResizableComponent

Create an instance of [ResizableComponent].

abstract @NonNull JxrPlatformAdapter.StereoSurfaceEntity
createStereoSurfaceEntity(
    int stereoMode,
    @NonNull JxrPlatformAdapter.Dimensions dimensions,
    @NonNull Pose pose,
    @NonNull JxrPlatformAdapter.Entity parentEntity
)

A factory function for an Entity which displays drawable surfaces.

abstract void

Disposes of the resources used by the platform adapter.

abstract @NonNull JxrPlatformAdapter.ActivitySpace

Returns the Activity Space entity at the root of the scene.

abstract @NonNull JxrPlatformAdapter.Entity

Returns the entity that represents the ActivitySpace root.

abstract @NonNull JxrPlatformAdapter.AudioTrackExtensionsWrapper

Returns an [AudioTrackExtensionssWrapper] instance.

abstract @Nullable JxrPlatformAdapter.CameraViewActivityPose
getCameraViewActivityPose(int cameraType)

Returns the CameraViewActivityPose for the specified camera type or null if it is not ready/available.

abstract @Nullable JxrPlatformAdapter.HeadActivityPose

Returns the HeadActivityPose for the Session or null if it is not ready

abstract @NonNull JxrPlatformAdapter.PanelEntity

Get the PanelEntity associated with the main window for the Activity.

abstract @NonNull JxrPlatformAdapter.MediaPlayerExtensionsWrapper

Returns a [MediaPlayerExtensionsWrapper] instance.

abstract @NonNull JxrPlatformAdapter.PerceptionSpaceActivityPose

Returns the PerceptionSpaceActivityPose for the Session.

abstract @NonNull JxrPlatformAdapter.SoundPoolExtensionsWrapper

Returns a [SoundPoolExtensionsWrapper] instance.

abstract @NonNull JxrPlatformAdapter.SpatialCapabilities

Return the Spatial Capabilities set that are currently supported by the platform.

abstract @NonNull JxrPlatformAdapter.SpatialEnvironment

Returns the Environment for the Session.

abstract @Nullable ListenableFuture<JxrPlatformAdapter.ExrImageResource>

Loads an ExrImage for the given asset name from the assets folder.

abstract @Nullable ListenableFuture<JxrPlatformAdapter.GltfModelResource>

Loads glTF Asset for the given asset name from the assets folder.

abstract @Nullable ListenableFuture<JxrPlatformAdapter.GltfModelResource>

Loads glTF Asset for the given asset name from the assets folder using the Split Engine route.

abstract void

Releases the given Consumer from receiving updates when the Session's change.

abstract void

If the primary Activity for this Session has focus, causes it to be placed in FullSpace Mode.

abstract void

If the primary Activity for this Session has focus, causes it to be placed in HomeSpace Mode.

abstract @NonNull Bundle

Sets the full space mode flag to the given Bundle.

abstract @NonNull Bundle

Sets the inherit full space mode environment flag to the given Bundle.

abstract void
setPreferredAspectRatio(@NonNull Activity activity, float preferredRatio)

Sets a preferred main panel aspect ratio for home space mode.

abstract void

Starts the SceneCore renderer.

abstract void

Stops the SceneCore renderer.

abstract boolean

Unpersist an AnchorEntity.

Public methods

addSpatialCapabilitiesChangedListener

Added in 1.0.0-alpha01
abstract void addSpatialCapabilitiesChangedListener(
    @NonNull Executor callbackExecutor,
    @NonNull Consumer<JxrPlatformAdapter.SpatialCapabilities> listener
)

Adds the given Consumer as a listener to be invoked when this Session's current SpatialCapabilities change. accept will be invoked on the given Executor.

createActivityPanelEntity

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.ActivityPanelEntity createActivityPanelEntity(
    @NonNull Pose pose,
    @NonNull JxrPlatformAdapter.PixelDimensions windowBoundsPx,
    @NonNull String name,
    @NonNull Activity hostActivity,
    @NonNull JxrPlatformAdapter.Entity parent
)

Factory function to create ActivityPanel to launch/move activity into.

Parameters
@NonNull Pose pose

Initial pose of the panel.

@NonNull JxrPlatformAdapter.PixelDimensions windowBoundsPx

Boundary for the window

@NonNull String name

Name of the panel.

@NonNull Activity hostActivity

Activity to host the panel.

@NonNull JxrPlatformAdapter.Entity parent

Parent entity.

createAnchorEntity

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.AnchorEntity createAnchorEntity(@NonNull Anchor anchor)

A factory function to create an Anchor entity from a androidx.xr.arcore.Anchor.

Parameters
@NonNull Anchor anchor

The androidx.xr.arcore.Anchor to create the Anchor entity from.

createAnchorEntity

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.AnchorEntity createAnchorEntity(
    @NonNull JxrPlatformAdapter.Dimensions bounds,
    @NonNull JxrPlatformAdapter.PlaneType planeType,
    @NonNull JxrPlatformAdapter.PlaneSemantic planeSemantic,
    @NonNull Duration searchTimeout
)

A factory function to create an Anchor entity.

Parameters
@NonNull JxrPlatformAdapter.Dimensions bounds

Bounds for this Anchor.

@NonNull JxrPlatformAdapter.PlaneType planeType

Orientation of the plane to which this anchor should attach.

@NonNull JxrPlatformAdapter.PlaneSemantic planeSemantic

Semantic type of the plane to which this anchor should attach.

@NonNull Duration searchTimeout

How long to search for an anchor. If this is Duration.ZERO, this will search for an anchor indefinitely.

createAnchorPlacementForPlanes

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.AnchorPlacement createAnchorPlacementForPlanes(
    @NonNull Set<JxrPlatformAdapter.PlaneType> planeTypeFilter,
    @NonNull Set<JxrPlatformAdapter.PlaneSemantic> planeSemanticFilter
)

Creates an instance of an AnchorPlacement object.

This can be used in movable components to specify the anchor placement for the entity.

Parameters
@NonNull Set<JxrPlatformAdapter.PlaneType> planeTypeFilter

A set of plane types to filter for.

@NonNull Set<JxrPlatformAdapter.PlaneSemantic> planeSemanticFilter

A set of plane semantics to filter for.

Returns
@NonNull JxrPlatformAdapter.AnchorPlacement

[AnchorPlacement] instance.

createEntity

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.Entity createEntity(
    @NonNull Pose pose,
    @NonNull String name,
    @NonNull JxrPlatformAdapter.Entity parent
)

A factory function to create a content-less entity. This entity is used as a connection point for attaching children entities and managing them (i.e. setPose()) as a group.

Parameters
@NonNull Pose pose

Initial pose of the entity.

@NonNull String name

Name of the entity.

@NonNull JxrPlatformAdapter.Entity parent

Parent entity.

createGltfEntity

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.GltfEntity createGltfEntity(
    @NonNull Pose pose,
    @NonNull JxrPlatformAdapter.GltfModelResource loadedGltf,
    @Nullable JxrPlatformAdapter.Entity parentEntity
)

A factory function to create a SceneCore GltfEntity. The parent may be the activity space or GltfEntity in the scene.

createInteractableComponent

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.InteractableComponent createInteractableComponent(
    @NonNull Executor executor,
    @NonNull JxrPlatformAdapter.InputEventListener listener
)

Create an Interactable component.

Parameters
@NonNull Executor executor

Executor to use for input callbacks.

@NonNull JxrPlatformAdapter.InputEventListener listener

[JxrPlatformAdapter.InputEventListener] for this component.

Returns
@NonNull JxrPlatformAdapter.InteractableComponent

InteractableComponent instance.

createLoggingEntity

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.LoggingEntity createLoggingEntity(@NonNull Pose pose)

A function to create a SceneCore Entity

createMovableComponent

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.MovableComponent createMovableComponent(
    boolean systemMovable,
    boolean scaleInZ,
    @NonNull Set<JxrPlatformAdapter.AnchorPlacement> anchorPlacement,
    boolean shouldDisposeParentAnchor
)

Create an instance of [MovableComponent]. This component allows the user to move the entity.

Parameters
boolean systemMovable

A [boolean] which causes the system to automatically apply transform updates to the entity in response to user interaction.

boolean scaleInZ

A [boolean] which tells the system to update the scale of the Entity as the user moves it closer and further away. This is mostly useful for Panel auto-rescaling with Distance

@NonNull Set<JxrPlatformAdapter.AnchorPlacement> anchorPlacement

AnchorPlacement information for when to anchor the entity.

boolean shouldDisposeParentAnchor

A [boolean] which tells the system to dispose of the parent anchor if that entity was created by the moveable component and is moved off of it.

Returns
@NonNull JxrPlatformAdapter.MovableComponent

[MovableComponent] instance.

createPanelEntity

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.PanelEntity createPanelEntity(
    @NonNull Pose pose,
    @NonNull View view,
    @NonNull JxrPlatformAdapter.PixelDimensions surfaceDimensionsPx,
    @NonNull JxrPlatformAdapter.Dimensions dimensions,
    @NonNull String name,
    @NonNull Context context,
    @NonNull JxrPlatformAdapter.Entity parent
)

A factory function to create a platform PanelEntity. The parent can be any entity.

Parameters
@NonNull Pose pose

Initial pose of the panel.

@NonNull View view

View inflating this panel.

@NonNull JxrPlatformAdapter.PixelDimensions surfaceDimensionsPx

Dimensions for the underlying surface for the given view.

@NonNull JxrPlatformAdapter.Dimensions dimensions

Size of the panel in meters.

@NonNull String name

Name of the panel.

@NonNull Context context

Application Context.

@NonNull JxrPlatformAdapter.Entity parent

Parent entity.

createPersistedAnchorEntity

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.AnchorEntity createPersistedAnchorEntity(
    @NonNull UUID uuid,
    @NonNull Duration searchTimeout
)

A factory function to recreate an Anchor entity which was persisted in a previous session.

Parameters
@NonNull UUID uuid

The UUID of the persisted anchor.

@NonNull Duration searchTimeout

How long to search for an anchor. If this is Duration.ZERO, this will search for an anchor indefinitely.

createPointerCaptureComponent

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.PointerCaptureComponent createPointerCaptureComponent(
    @NonNull Executor executor,
    @NonNull JxrPlatformAdapter.PointerCaptureComponent.StateListener stateListener,
    @NonNull JxrPlatformAdapter.InputEventListener inputListener
)

Create an instance of PointerCaptureComponent. This component allows the user to capture and redirect to itself all input that would be received by entities other than the Entity it is attached to and that entity's children.

In order to enable pointer capture, an application must be in full space and the entity it is attached to must be visible.

Attach this component to the entity to enable pointer capture, detach the component to restore normal input flow.

Parameters
@NonNull Executor executor

Executor used to propagate state and input events.

@NonNull JxrPlatformAdapter.PointerCaptureComponent.StateListener stateListener

Callback for updates to the state of pointer capture. Pointer capture may be temporarily lost by the application for a variety of reasons and this callback will notify of when that happens.

@NonNull JxrPlatformAdapter.InputEventListener inputListener

Callback that will receive captured [InputEvent]s

createResizableComponent

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.ResizableComponent createResizableComponent(
    @NonNull JxrPlatformAdapter.Dimensions minimumSize,
    @NonNull JxrPlatformAdapter.Dimensions maximumSize
)

Create an instance of [ResizableComponent]. This component allows the user to resize the entity.

Parameters
@NonNull JxrPlatformAdapter.Dimensions minimumSize

Minimum size constraint.

@NonNull JxrPlatformAdapter.Dimensions maximumSize

Maximum size constraint.

Returns
@NonNull JxrPlatformAdapter.ResizableComponent

[ResizableComponent] instance.

createStereoSurfaceEntity

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.StereoSurfaceEntity createStereoSurfaceEntity(
    int stereoMode,
    @NonNull JxrPlatformAdapter.Dimensions dimensions,
    @NonNull Pose pose,
    @NonNull JxrPlatformAdapter.Entity parentEntity
)

A factory function for an Entity which displays drawable surfaces.

dispose

Added in 1.0.0-alpha01
abstract void dispose()

Disposes of the resources used by the platform adapter.

getActivitySpace

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.ActivitySpace getActivitySpace()

Returns the Activity Space entity at the root of the scene.

getActivitySpaceRootImpl

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.Entity getActivitySpaceRootImpl()

Returns the entity that represents the ActivitySpace root.

SDK's factory methods are expected to use this entity as the default parent for all content entities when no parent is specified.

getAudioTrackExtensionsWrapper

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.AudioTrackExtensionsWrapper getAudioTrackExtensionsWrapper()

Returns an [AudioTrackExtensionssWrapper] instance.

getCameraViewActivityPose

Added in 1.0.0-alpha01
abstract @Nullable JxrPlatformAdapter.CameraViewActivityPose getCameraViewActivityPose(int cameraType)

Returns the CameraViewActivityPose for the specified camera type or null if it is not ready/available.

getHeadActivityPose

Added in 1.0.0-alpha01
abstract @Nullable JxrPlatformAdapter.HeadActivityPose getHeadActivityPose()

Returns the HeadActivityPose for the Session or null if it is not ready

getMainPanelEntity

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.PanelEntity getMainPanelEntity()

Get the PanelEntity associated with the main window for the Activity.

getMediaPlayerExtensionsWrapper

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.MediaPlayerExtensionsWrapper getMediaPlayerExtensionsWrapper()

Returns a [MediaPlayerExtensionsWrapper] instance.

getPerceptionSpaceActivityPose

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.PerceptionSpaceActivityPose getPerceptionSpaceActivityPose()

Returns the PerceptionSpaceActivityPose for the Session.

getSoundPoolExtensionsWrapper

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.SoundPoolExtensionsWrapper getSoundPoolExtensionsWrapper()

Returns a [SoundPoolExtensionsWrapper] instance.

getSpatialCapabilities

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.SpatialCapabilities getSpatialCapabilities()

Return the Spatial Capabilities set that are currently supported by the platform.

getSpatialEnvironment

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.SpatialEnvironment getSpatialEnvironment()

Returns the Environment for the Session.

loadExrImageByAssetName

Added in 1.0.0-alpha01
abstract @Nullable ListenableFuture<JxrPlatformAdapter.ExrImageResourceloadExrImageByAssetName(@NonNull String assetName)

Loads an ExrImage for the given asset name from the assets folder.

loadGltfByAssetName

Added in 1.0.0-alpha01
abstract @Nullable ListenableFuture<JxrPlatformAdapter.GltfModelResourceloadGltfByAssetName(@NonNull String assetName)

Loads glTF Asset for the given asset name from the assets folder.

loadGltfByAssetNameSplitEngine

Added in 1.0.0-alpha01
abstract @Nullable ListenableFuture<JxrPlatformAdapter.GltfModelResourceloadGltfByAssetNameSplitEngine(@NonNull String assetName)

Loads glTF Asset for the given asset name from the assets folder using the Split Engine route. The future returned by this method will fire listeners on the UI thread if Runnable::run is supplied.

removeSpatialCapabilitiesChangedListener

Added in 1.0.0-alpha01
abstract void removeSpatialCapabilitiesChangedListener(
    @NonNull Consumer<JxrPlatformAdapter.SpatialCapabilities> listener
)

Releases the given Consumer from receiving updates when the Session's change.

requestFullSpaceMode

Added in 1.0.0-alpha01
abstract void requestFullSpaceMode()

If the primary Activity for this Session has focus, causes it to be placed in FullSpace Mode. Otherwise, this call does nothing.

requestHomeSpaceMode

Added in 1.0.0-alpha01
abstract void requestHomeSpaceMode()

If the primary Activity for this Session has focus, causes it to be placed in HomeSpace Mode. Otherwise, this call does nothing.

setFullSpaceMode

Added in 1.0.0-alpha01
abstract @NonNull Bundle setFullSpaceMode(@NonNull Bundle bundle)

Sets the full space mode flag to the given Bundle.

The Bundle then could be used to launch an Activity with requesting to enter full space mode through startActivity. If there's a bundle used for customizing how the Activity should be started by ActivityOptions.toBundle or androidx.core.app.ActivityOptionsCompat.toBundle, it's suggested to use the bundle to call this method.

The flag will be ignored when no Intent.FLAG_ACTIVITY_NEW_TASK is set in the bundle, or it is not started from a focused Activity context.

This flag is also ignored when the android.window.PROPERTY_XR_ACTIVITY_START_MODE property is set to a value other than XR_ACTIVITY_START_MODE_UNDEFINED in the AndroidManifest.xml file for the activity being launched.

Parameters
@NonNull Bundle bundle

the input bundle to set with the full space mode flag.

Returns
@NonNull Bundle

the input bundle with the full space mode flag set.

setFullSpaceModeWithEnvironmentInherited

Added in 1.0.0-alpha01
abstract @NonNull Bundle setFullSpaceModeWithEnvironmentInherited(@NonNull Bundle bundle)

Sets the inherit full space mode environment flag to the given Bundle.

The Bundle then could be used to launch an Activity with requesting to enter full space mode while inherit the existing environment through startActivity. If there's a bundle used for customizing how the Activity should be started by ActivityOptions.toBundle or , it's suggested to use the bundle to call this method.

When launched, the activity will be in full space mode and also inherits the environment from the launching activity. If the inherited environment needs to be animated, the launching activity has to continue updating the environment even after the activity is put into the stopped state.

The flag will be ignored when no Intent.FLAG_ACTIVITY_NEW_TASK is set in the intent, or it is not started from a focused Activity context.

The flag will also be ignored when there is no environment to inherit or the activity has its own environment set already.

This flag is ignored too when the android.window.PROPERTY_XR_ACTIVITY_START_MODE property is set to a value other than XR_ACTIVITY_START_MODE_UNDEFINED in the AndroidManifest.xml file for the activity being launched.

For security reasons, Z testing for the new activity is disabled, and the activity is always drawn on top of the inherited environment. Because Z testing is disabled, the activity should not spatialize itself, and should not curve its panel too much either.

Parameters
@NonNull Bundle bundle

the input bundle to set with the inherit full space mode environment flag.

Returns
@NonNull Bundle

the input bundle with the inherit full space mode flag set.

setPreferredAspectRatio

Added in 1.0.0-alpha01
abstract void setPreferredAspectRatio(@NonNull Activity activity, float preferredRatio)

Sets a preferred main panel aspect ratio for home space mode.

The ratio is only applied to the activity. If the activity launches another activity in the same task, the ratio is not applied to the new activity. Also, while the activity is in full space mode, the preference is temporarily removed.

Parameters
@NonNull Activity activity

the activity to set the preference.

float preferredRatio

the aspect ratio determined by taking the panel's width over its height. A value <= 0.0f means there are no preferences.

startRenderer

Added in 1.0.0-alpha01
abstract void startRenderer()

Starts the SceneCore renderer.

stopRenderer

Added in 1.0.0-alpha01
abstract void stopRenderer()

Stops the SceneCore renderer.

unpersistAnchor

Added in 1.0.0-alpha01
abstract boolean unpersistAnchor(@NonNull UUID uuid)

Unpersist an AnchorEntity. It will clean up the data in the storage that is required to retrieve the anchor. Returns whether the anchor was successfully unpersisted.

Parameters
@NonNull UUID uuid

UUID of the anchor to unpersist.