html5-audio

What are the limitations of HTML5 audio on Android and iOS?

浪尽此生 提交于 2019-12-21 03:55:24
问题 I've noticed that for the HTML5 Audio element, what works on the latest version of Chrome for PCs will not necessarily work on the default browser in Android, Chrome for Android, or Safari on iOS. What limitations exist for Audio on these platforms? Specifically: Which audio formats are supported on each platform? For each platform, is a user interaction event (eg. onclick) required to play audio from javascript? (via new Audio(url); ) Can audio be played from a data URI on the Android and

audio tag not working in IE9

℡╲_俬逩灬. 提交于 2019-12-20 15:11:40
问题 I'm experimenting with the audio tag. The file below does work in Google Chrome, but not in IE9. I'm always getting "audio tag not supported". I also tried wav, flac, wma --> same result. I suspect there might some issue with the compaitibility mode, but I don't find where to change it. Can anyone help? Kind regards Georg <html> <head> </head> <body> <audio controls="controls" src="c:\concerto.mp3" > audio tag not supported. </audio> </body> </html> 回答1: Add the HTML5 doctype to the page and

audio tag not working in IE9

£可爱£侵袭症+ 提交于 2019-12-20 15:09:06
问题 I'm experimenting with the audio tag. The file below does work in Google Chrome, but not in IE9. I'm always getting "audio tag not supported". I also tried wav, flac, wma --> same result. I suspect there might some issue with the compaitibility mode, but I don't find where to change it. Can anyone help? Kind regards Georg <html> <head> </head> <body> <audio controls="controls" src="c:\concerto.mp3" > audio tag not supported. </audio> </body> </html> 回答1: Add the HTML5 doctype to the page and

Get live streaming audio from NodeJS server to clients

落爺英雄遲暮 提交于 2019-12-20 12:30:55
问题 I need to have a real time live audio stream from 1 client to a server to multiple listener clients. Currently I have the recording from the client working and stream the audio through socket.io to the server. The server receives this data and must stream the audio (also through socket.io?) to the clients that want to listen to this stream. It must be as real time as possible (minimize delay). I'm using GetUserMedia to record the microphone (browser compatibility is not important here). I

HTML5 audio - play sound repeatedly on click, regardless if previous iteration has finished

本小妞迷上赌 提交于 2019-12-20 12:30:48
问题 I'm building a game in which a wav file plays on click - in this case it's a gun sound "bang". The problem is if I rapid click, it won't play the sound once for each click - it's as if the clicks are ignored while the sound is playing, and once the sound is finished, it starts listening for clicks again. The delay seems to be about one second long, so you figure if someone clicks 4 or 5 times per second, I want 5 bangs, not 1. Here's my HTML: <audio id="gun_sound" preload> <source src="http:/

HTML5 audio not playing multiple times in Android 4.0.4 device Native Browser

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-20 08:31:02
问题 I am currently working on an HTML5 project. There is an issue on playing same audio file multiple times in the same page in Android native browser . The issue is specifically noticed on Android ICS 4.0.4 version. In this version the audio will be played once , but when initiated again audio will not be played . The same thing is working perfectly in Android ICS 4.0.3 Version and on the newer 4.1.1 version. Tested Devices: Samsung Galaxy Tab (Android 4.0.4) : Playing first time only then it

JPlayer Circle Player does not show circle first time around with wav files made from vox

妖精的绣舞 提交于 2019-12-20 07:39:38
问题 I have an application that is using the JPlayer Circle Player to play short audios for transcription purposes. Each of these audios originates as a .vox file that has been converted to .wav by SoX. When the Play button is pressed, the audio plays but the green circle does not display. Once the clip has played, pressing play again does show the green circle advancing. I assume that this is because either the original vox format or the wav format does not contain any length data so that player

Javascript audio loop

放肆的年华 提交于 2019-12-20 06:34:36
问题 I want to play an audio in background 3 times and after 3 times the audio will stop automaticlly. I've tried this code and it did not work. HTML CODE: <audio id='beep' controls> <source src="beep-02.mp3" type="audio/mpeg"> Your browser does not support the audio element. </audio> JAVASCRIPT: var count = 1 document.getElementById('beep').addEventListener('ended', function(){ this.currentTime = 0; if(count <= 3){ this.play(); } count++; }, false); Thanks. 回答1: You could try using onended:

Setting currentTime attribute programatically on audio element causes event listeners to fire indefinitely

旧巷老猫 提交于 2019-12-20 06:27:34
问题 As the title states, this behavior occurs when setting the currentTime attribute on an audio element programatically. When that value is set, the event listeners get fired over and over indefinitely. The audio will try to play, but since there is so much processing going on, the audio will skip and my browser will start to become unresponsive. I've solved the problem by removing the binding to the currentTime variable, but I am just asking if anyone has some insight as to why this is

background HTML5 WebApps on Android 2.3+

一个人想着一个人 提交于 2019-12-20 03:09:04
问题 iOS 4.2+ allows certain webapps to run in the background, without any special requirements. How is it possible to run a webapp in the background on Android (to continue playing music, for example)? For an example, see http://sandbox.coolaj86.info/html5-audio-tag.html Begin playing the music sample on your iPod/iPad/iPhone, then click to "background" the app. Double click and swipe from left to right in the lower menu to access the player controls. 回答1: That is done by using background