# SpatialMediaPlayerTester

Artifact: [androidx.xr.scenecore:scenecore-testing](https://developer.android.com/jetpack/androidx/releases/xr-scenecore) [View Source](https://cs.android.com/search?q=file:androidx/xr/scenecore/testing/SpatialMediaPlayerTester.kt+class:androidx.xr.scenecore.testing.SpatialMediaPlayerTester) Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/xr-scenecore#1.0.0)

*** ** * ** ***


```
class SpatialMediaPlayerTester
```

<br />

*** ** * ** ***

A test utility for accessing and inspecting the spatial data associated with the `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/SpatialMediaPlayer`.

## Summary

| ### Public functions |
|---|---|
| `open operator https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/testing/SpatialMediaPlayerTester#equals(kotlin.Any)(other: https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-any/index.html?)` |
| `open https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html` | `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/testing/SpatialMediaPlayerTester#hashCode()()` |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/testing/SpatialMediaPlayerTester#isCurrentPointSource(androidx.xr.scenecore.Entity)(entity: https://developer.android.com/reference/kotlin/androidx/xr/scenecore/Entity)` Checks whether the given `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/testing/SpatialMediaPlayerTester#isCurrentPointSource(androidx.xr.scenecore.Entity)` is currently configured as the point source for the associated `https://developer.android.com/reference/android/media/MediaPlayer.html`. |

| ### Public properties |
|---|---|
| `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/PointSourceParams?` | `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/testing/SpatialMediaPlayerTester#pointSourceParams()` The `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/PointSourceParams` that are currently set for this `https://developer.android.com/reference/android/media/MediaPlayer.html`. |
| `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/SoundFieldAttributes?` | `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/testing/SpatialMediaPlayerTester#soundFieldAttributes()` The `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/SoundFieldAttributes` that are currently set for this `https://developer.android.com/reference/android/media/MediaPlayer.html`. |

## Public functions

### equals

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

### hashCode

```
open fun hashCode(): Int
```

### isCurrentPointSource

Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/xr-scenecore#1.0.0)

```
fun isCurrentPointSource(entity: Entity): Boolean
```

Checks whether the given `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/testing/SpatialMediaPlayerTester#isCurrentPointSource(androidx.xr.scenecore.Entity)` is currently configured as the point source for the associated `https://developer.android.com/reference/android/media/MediaPlayer.html`.

This returns `true` if the `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/testing/SpatialMediaPlayerTester#isCurrentPointSource(androidx.xr.scenecore.Entity)` was passed to `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/SpatialMediaPlayer#setPointSourceParams(androidx.xr.runtime.Session,android.media.MediaPlayer,androidx.xr.scenecore.PointSourceParams,androidx.xr.scenecore.Entity)` for this `https://developer.android.com/reference/android/media/MediaPlayer.html`.

| Parameters |
|---|---|
| `entity: https://developer.android.com/reference/kotlin/androidx/xr/scenecore/Entity` | The target `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/Entity` to check against. |

| Returns |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html` | `true` if the `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/testing/SpatialMediaPlayerTester#isCurrentPointSource(androidx.xr.scenecore.Entity)` is the point source for the `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/testing/SpatialMediaPlayerTester#mediaPlayer()`, `false` otherwise. |

## Public properties

### pointSourceParams

Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/xr-scenecore#1.0.0)

```
val pointSourceParams: PointSourceParams?
```

The `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/PointSourceParams` that are currently set for this `https://developer.android.com/reference/android/media/MediaPlayer.html`.

This is useful for verifying if the `https://developer.android.com/reference/android/media/MediaPlayer.html` has been updated with the intended parameters via `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/SpatialMediaPlayer#setPointSourceParams(androidx.xr.runtime.Session,android.media.MediaPlayer,androidx.xr.scenecore.PointSourceParams,androidx.xr.scenecore.Entity)`.

### soundFieldAttributes

Added in [1.0.0](https://developer.android.com/jetpack/androidx/releases/xr-scenecore#1.0.0)

```
val soundFieldAttributes: SoundFieldAttributes?
```

The `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/SoundFieldAttributes` that are currently set for this `https://developer.android.com/reference/android/media/MediaPlayer.html`.

This is useful for verifying if the `https://developer.android.com/reference/android/media/MediaPlayer.html` has been updated with the intended attributes via `https://developer.android.com/reference/kotlin/androidx/xr/scenecore/SpatialMediaPlayer#setSoundFieldAttributes(androidx.xr.runtime.Session,android.media.MediaPlayer,androidx.xr.scenecore.SoundFieldAttributes)`.