playdate.sound.fileplayer getLength() / getOffset() return incorrect values since SDK 1.10.0
limport "CoreLibs/graphics"
local gfx <const> = playdate.graphics
local fp = playdate.sound.fileplayer.new("resource/test.mp3")
fp:play()
function playdate.update()
gfx.clear()
gfx.drawText("Length:" .. tostring(fp:getLength()), 10, 10)
gfx.drawText("Offset: " .. tostring(fp:getOffset()), 10, 50)
end
SDK 1.9.3:
SDK 1.10.0:
getLength() returns a fixed decimal value.
getOffset() returns almost the same value, even during playback.
Reproduced on Windows/Mac Simulator and Playdate Device.
This has been occurring since updating to SDK 1.10.0