music playlist is working again

This commit is contained in:
minjaesong
2023-11-18 13:13:19 +09:00
parent 7219b95542
commit 62c7b36a46
6 changed files with 56 additions and 19 deletions

View File

@@ -116,10 +116,14 @@ class TerrarumAudioMixerTrack(val name: String, val isMaster: Boolean = false):
override fun equals(other: Any?) = this.hash == (other as TerrarumAudioMixerTrack).hash
fun fireSongFinishHook() {
currentTrack?.songFinishedHook?.invoke(currentTrack!!.gdxMusic)
}
// 1st ring of the hell: the THREADING HELL //
val BUFFER_SIZE = 8192
val BUFFER_SIZE = 16384
internal var processor = MixerTrackProcessor(BUFFER_SIZE, SAMPLING_RATE, this)
private val processorThread = Thread(processor).also {