gskinner / JustAddMusic

Easily add music and music visualization to your web experiences.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Handle errors on "decodeAudioData"

lannymcnie opened this issue · comments

In Safari and Firefox (OS X) I encountered an issue with audio that loaded, but failed to decode. Currently JAM does not handle or surface this error. Ideally it would console.error, or dispatch an event.

Here is a file that failed. It is 44kbps. When it was re-encoded for 48kbps, it worked fine, so that could be the cause. The error happens specifically when the file is loaded in an iframe, and it seemed to work fine when loaded in its own window.