jukebox wip

This commit is contained in:
minjaesong
2024-01-11 02:23:20 +09:00
parent 52ae1768cb
commit fd30223df8
9 changed files with 127 additions and 3 deletions

View File

@@ -411,7 +411,7 @@ object AudioMixer: Disposable {
requestFadeOut(ambientTrack, DEFAULT_FADEOUT_LEN * 4)
}
fun requestFadeOut(track: TerrarumAudioMixerTrack, length: Double, target: Double = 0.0, source: Double? = null, jobAfterFadeout: () -> Unit = {}) {
fun requestFadeOut(track: TerrarumAudioMixerTrack, length: Double = DEFAULT_FADEOUT_LEN, target: Double = 0.0, source: Double? = null, jobAfterFadeout: () -> Unit = {}) {
val req = fadeReqs[track]!!
if (!req.fadeoutFired) {
req.fadeLength = length.coerceAtLeast(1.0/1024.0)

View File

@@ -37,7 +37,7 @@ class MixerTrackProcessor(val buffertaille: Int, val rate: Int, val track: Terra
private var breakBomb = false
private val distFalloff = 2048.0
private val distFalloff = 1024.0
private fun printdbg(msg: Any) {
if (true) App.printdbg("AudioAdapter ${track.name}", msg)