mirror of
https://github.com/curioustorvald/Terrarum.git
synced 2026-06-21 16:04:05 +09:00
audio engine: resize buffer without restarting the game
This commit is contained in:
@@ -91,9 +91,6 @@ class Spectro(val gain: Float = 1f) : TerrarumAudioFilter() {
|
||||
}
|
||||
|
||||
override val debugViewHeight = STRIP_W
|
||||
|
||||
override fun reset() {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -157,13 +154,4 @@ class Vecto(val gain: Float = 1f) : TerrarumAudioFilter() {
|
||||
}
|
||||
|
||||
override val debugViewHeight = STRIP_W
|
||||
|
||||
override fun reset() {
|
||||
backbufL = Array((6144f / App.audioBufferSize).roundToInt().coerceAtLeast(1)) {
|
||||
FloatArray(App.audioBufferSize)
|
||||
}
|
||||
backbufR = Array((6144f / App.audioBufferSize).roundToInt().coerceAtLeast(1)) {
|
||||
FloatArray(App.audioBufferSize)
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user