code cleanup

This commit is contained in:
minjaesong
2020-11-11 10:40:10 +09:00
parent 4db5bc1623
commit ab780fd246
36 changed files with 274 additions and 716 deletions

View File

@@ -366,7 +366,7 @@ class LuaComputerVM(val display: MDA) {
if (sine > 0.79) sine = 0.79
else if (sine < -0.79) sine = -0.79
audioData.put(
(0.5 + 0.5 * sine).times(0xFF).roundInt().toByte()
(0.5 + 0.5 * sine).times(0xFF).roundToInt().toByte()
)
}
}
@@ -377,7 +377,7 @@ class LuaComputerVM(val display: MDA) {
sine += Math.sin(Math.PI * 2 * (2*k - 1) * chopSize * x) / (2*k - 1)
}
audioData.put(
(0.5 + 0.5 * sine).times(0xFF).roundInt().toByte()
(0.5 + 0.5 * sine).times(0xFF).roundToInt().toByte()
)
}
}*/

View File

@@ -509,7 +509,7 @@ class TerrarumComputerOldOld(peripheralSlots: Int) {
if (sine > 0.79) sine = 0.79
else if (sine < -0.79) sine = -0.79
audioData.put(
(0.5 + 0.5 * sine).times(0xFF).roundInt().toByte()
(0.5 + 0.5 * sine).times(0xFF).roundToInt().toByte()
)
}
}
@@ -520,7 +520,7 @@ class TerrarumComputerOldOld(peripheralSlots: Int) {
sine += Math.sin(Math.PI * 2 * (2*k - 1) * chopSize * x) / (2*k - 1)
}
audioData.put(
(0.5 + 0.5 * sine).times(0xFF).roundInt().toByte()
(0.5 + 0.5 * sine).times(0xFF).roundToInt().toByte()
)
}
}*/