JxrPlatformAdapter.SoundPoolExtensionsWrapper


interface JxrPlatformAdapter.SoundPoolExtensionsWrapper


Interface for a SceneCore SoundPoolExtensionsWrapper.

Summary

Public functions

Int
getSpatialSourceType(soundPool: SoundPool, streamId: Int)

Returns the spatial source type of the sound.

Int
play(
    soundPool: SoundPool,
    soundId: Int,
    attributes: JxrPlatformAdapter.PointSourceAttributes,
    volume: Float,
    priority: Int,
    loop: Int,
    rate: Float
)

Plays a sound as a point source.

Int
play(
    soundPool: SoundPool,
    soundId: Int,
    attributes: JxrPlatformAdapter.SoundFieldAttributes,
    volume: Float,
    priority: Int,
    loop: Int,
    rate: Float
)

Plays a sound as a sound field.

Public functions

getSpatialSourceType

Added in 1.0.0-alpha02
fun getSpatialSourceType(soundPool: SoundPool, streamId: Int): Int

Returns the spatial source type of the sound.

Parameters
soundPool: SoundPool

The SoundPool to use.

streamId: Int

The stream ID of the sound.

Returns
Int

The spatial source type of the sound.

play

Added in 1.0.0-alpha02
fun play(
    soundPool: SoundPool,
    soundId: Int,
    attributes: JxrPlatformAdapter.PointSourceAttributes,
    volume: Float,
    priority: Int,
    loop: Int,
    rate: Float
): Int

Plays a sound as a point source.

Parameters
soundPool: SoundPool

The SoundPool to use.

soundId: Int

The ID of the sound to play.

attributes: JxrPlatformAdapter.PointSourceAttributes

The PointSourceAttributes to use.

volume: Float

The volume of the sound.

priority: Int

The priority of the sound.

loop: Int

Whether to loop the sound.

rate: Float

The playback rate of the sound.

Returns
Int

The result of the play operation.

play

Added in 1.0.0-alpha02
fun play(
    soundPool: SoundPool,
    soundId: Int,
    attributes: JxrPlatformAdapter.SoundFieldAttributes,
    volume: Float,
    priority: Int,
    loop: Int,
    rate: Float
): Int

Plays a sound as a sound field.

Parameters
soundPool: SoundPool

The SoundPool to use.

soundId: Int

The ID of the sound to play.

attributes: JxrPlatformAdapter.SoundFieldAttributes

The SoundFieldAttributes to use.

volume: Float

The volume of the sound.

priority: Int

The priority of the sound.

loop: Int

Whether to loop the sound.

rate: Float

The playback rate of the sound.

Returns
Int

The result of the play operation.