我试着用tone.js播放我的主机的音频样本,但是没有声音。
我尝试使用tone.js的这段代码,它可以工作:
const player2 = new Tone.Player("https://tonejs.github.io/audio/berklee/gong_1.mp3").toDestination();当我用我的直接主机链接更改"https://tonejs.github.io/audio/berklee/gong_1.mp3“链接时,没有声音。
发布于 2022-01-14 14:52:21
我认为这与您的主机有问题,(尝试更改您的文件的权限),尝试这个链接,它是我的主机,它对我有效。
player = new Tone.Player("https://vivo-vivendo-musica.com/sample/1_Hat.mp3").toDestination();
// play as soon as the buffer is loaded
player.autostart = true;https://stackoverflow.com/questions/70711965
复制相似问题