ws-audio2: Monkey's Audio: codecs/audio/Ape (port of the MAC SDK 13.28 decoder, BSD-3) + audio/ape
File versions 3.95+ (3.99+ verified; the 3.95-3.98 range-coder model is ported without a reference fixture), every level (fast .. insane), 8/16/24/32-bit int and 32-bit float, 1-32 channels, special frames, frame CRCs, seeking, APEv2 tags, ID3v2 in front. 35 fixtures (mac 13.28, the FATE luckynight sample) bit-exact against mac -d. tests/audio/_lossless.luau: the per-fixture checks shared by the lossless format tests. tools/bench.luau: the ws-audio2 lossless block.
This commit is contained in:
1 parent
66c3819063
commit
ae8ff9d6bf
12 files changed
+1543
-99
No files matched your search
@@ -1078,3 +1078,26 @@ do
|
||||
jitTune(false)
|
||||
end
|
||||
end
|
||||
-- ws-audio2: lossless
|
||||
do
|
||||
-- WavPack / Monkey's Audio / TTA decoders (tools/fixtures/wavpack.py, ape.py, tta.py): MB/s of f32 output
|
||||
local function lossless(label: string, mod: any, data: string)
|
||||
local b = buffer.fromstring(data)
|
||||
local dec = assert(mod.open(Bytes.reader(b)))
|
||||
bench(label, 5, dec.frames * dec.channels * 4, function()
|
||||
mod.decode(Bytes.reader(b))
|
||||
end)
|
||||
end
|
||||
local Wv = require("@formats/audio/wavpack")
|
||||
for _, c in require("@tests/gen/wavpack_cases") do
|
||||
if c.name == "s16_long" or c.name == "s16_hh" or c.name == "s24_hh" or c.name == "f32" or c.name == "hyb_b3" then
|
||||
lossless("wavpack " .. c.name, Wv, c.data)
|
||||
end
|
||||
end
|
||||
local ApeF = require("@formats/audio/ape")
|
||||
for _, c in require("@tests/gen/ape_cases") do
|
||||
if c.name == "s16_long" or c.name == "s16_long_c4000" or c.name == "s16_c5000" or c.name == "s24" or c.name == "s16_c1000" then
|
||||
lossless("ape " .. c.name, ApeF, c.data)
|
||||
end
|
||||
end
|
||||
end
|
||||
Reference in new issue
Block a user