JxrPlatformAdapter.ActivitySpace


public interface JxrPlatformAdapter.ActivitySpace extends JxrPlatformAdapter.SystemSpaceEntity


Interface for a SceneCore activity space. There is one activity space and it is the ancestor for all elements in the scene. The activity space does not have a parent.

Summary

Nested types

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

Public methods

abstract void

Adds a listener to be called when the bounds of the primary Activity change.

abstract @NonNull JxrPlatformAdapter.Dimensions

Returns the bounds of this ActivitySpace.

abstract void

Removes a listener to be called when the bounds of the primary Activity change.

Inherited methods

From androidx.xr.scenecore.JxrPlatformAdapter.ActivityPose
abstract @NonNull Pose

Returns the pose for this entity, relative to the activity space root.

abstract @NonNull Vector3

Returns the scale of this WorldPose relative to the activity space.

abstract @NonNull Vector3

Returns the scale of this ActivityPose.

abstract @NonNull Pose

Returns a pose relative to this entity transformed into a pose relative to the destination.

From androidx.xr.scenecore.JxrPlatformAdapter.Entity
abstract void

Add given Entity as child.

abstract void
abstract boolean

Add these components to entity.

abstract void

Adds the listener to the set of active input listeners, for input events targeted to this entity or its child entities.

abstract void

Dispose any system resources held by this entity, and transitively calls dispose() on all the children.

abstract float

Returns the total alpha transparency level for this Entity.

abstract float

Returns the set alpha transparency level for this Entity.

abstract @NonNull List<JxrPlatformAdapter.Entity>
abstract @Nullable JxrPlatformAdapter.Entity
abstract @NonNull Pose

Returns the pose for this entity, relative to its parent.

abstract @NonNull Vector3

Returns the scale of this entity, relative to its parent.

abstract boolean
isHidden(boolean includeParents)

Returns the hidden status of this Entity.

abstract void

Remove all components from this entity.

abstract void

Remove the given component from the entity.

abstract void

Removes the given listener from the set of active input listeners.

abstract void
setAlpha(float alpha)

Sets the alpha transparency for the given Entity.

abstract void
abstract void
setHidden(boolean hidden)

Sets the local hidden state of this Entity.

abstract void
abstract void

Updates the pose (position and rotation) of the Entity relative to its parent.

abstract void

Sets the scale of this entity relative to its parent.

abstract void

Sets the size for the given Entity.

From androidx.xr.scenecore.JxrPlatformAdapter.SystemSpaceEntity
abstract void

Registers a listener to be called when the underlying space has moved or changed.

Public methods

addOnBoundsChangedListener

Added in 1.0.0-alpha01
abstract void addOnBoundsChangedListener(
    @NonNull JxrPlatformAdapter.ActivitySpace.OnBoundsChangedListener listener
)

Adds a listener to be called when the bounds of the primary Activity change. If the same listener is added multiple times, it will only fire each event on time.

Parameters
@NonNull JxrPlatformAdapter.ActivitySpace.OnBoundsChangedListener listener

The listener to register.

getBounds

Added in 1.0.0-alpha01
abstract @NonNull JxrPlatformAdapter.Dimensions getBounds()

Returns the bounds of this ActivitySpace.

removeOnBoundsChangedListener

Added in 1.0.0-alpha01
abstract void removeOnBoundsChangedListener(
    @NonNull JxrPlatformAdapter.ActivitySpace.OnBoundsChangedListener listener
)

Removes a listener to be called when the bounds of the primary Activity change. If the given listener was not added, this call does nothing.

Parameters
@NonNull JxrPlatformAdapter.ActivitySpace.OnBoundsChangedListener listener

The listener to unregister.