guo-yu / player

a command line player, supports play mp3 both from uri and local stream.
261 stars 66 forks source link

如何调整播放的时间 #39

Closed stkevintan closed 8 years ago

stkevintan commented 9 years ago

RT 本人用nw.js写了一个图形界面播放器(html+io.js):https://github.com/stkevintan/nw_musicbox 目前使用的是html5的audio标签。想迁徙到这个项目中。 但是,该如何调整播放时间呢?

guo-yu commented 9 years ago

现在是没有这个功能的,我建议说如果要完成全功能的播放器效果,还是用 Web 来实现比较方便

stkevintan commented 9 years ago

嗯,看了你的代码感觉这个功能不怎么好实现,但是还是好奇是否真的有一种实现方法。 之所以不想用浏览器提供的audio标签是因为nw.js绑定的chromium默认不支持mp3等常见格式的解码,而解决办法比较繁琐。 以后,暂时决定用Web Audio API代替audio标签吧,虽然还是依赖于浏览器,但是接口丰富。 thx!

guo-yu commented 8 years ago

现在 player 模块支持了暂停和音量条件的功能,不过暂时还没有支持随意调整播放时间。