admin管理员组文章数量:1357307
Is there a way to change the playback speed of audio in the browser? What is best to acplish this task, html5 audio, or flash, or something else? Are there any specific libraries that would help with this?
Is there a way to change the playback speed of audio in the browser? What is best to acplish this task, html5 audio, or flash, or something else? Are there any specific libraries that would help with this?
Share Improve this question asked Mar 8, 2013 at 8:49 pepperpepper 2,1975 gold badges26 silver badges31 bronze badges2 Answers
Reset to default 4Use the Web Audio API.
In the following code I answered your other question.
best way to loop audio in the browser?
Modify the code in my answer above as follows for a playback speed example.
Right below
source.loop = loopOnOff;
add
source.playbackRate.value = 1; // change number to between 0.10 to 10 (or larger/smaller) to test.
You can also run the html audio tag through the web audio api and add effects processing.
Interesting question there,
HTMl5 will have player speed control will have speed control..
A couple of noteworthy uping features are playbackRate and defaultPlaybackRate. As you can probably imagine, these fellas let us alter the speed and direction of playback. This functionality could be used for fast-forward and rewind functions or perhaps to allow users to tweak the playback speed so they can fit more podcasts into their day.
audio.playbackRate returns 1 at normal speed and acts as a multiple that is applied to the rate of playback. For example, setting playbackRate to 2 would double the speed, while setting it to -1 would play the media backwards. audio.defaultPlaybackRate is the rate at which the audio will play after you pause and restart the media (or issue any event for that matter).
Flash Player may help( but it will be customized one you may create, with stream buffer, you need to define the player speed once buffer has the content to play.
Sound easy but will take a lot effort, Refer VLC opesource for better Idea, its documented with ffmpeg which works with Audio, and works with client software, in browser ti will be heavy, refer Just to have idea.
I hope this may help :)
本文标签: javascriptvariable speed control for audio playback in the browserStack Overflow
版权声明:本文标题:javascript - variable speed control for audio playback in the browser? - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1744039199a2580347.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论