CreateMediaElementSource Web Audio API Method in Firefox

According to the Mozilla WebAudio Rollout API , WebAudio must be available in Firefox 25.0.1. However, I cannot get it to createMediaElementSourcework with Firefox, but it works fine in Chrome. Here is a simplified version of the code:

var context = new AudioContext();
var el = document.getElementById('audio');
// Breaks in Firefox.  Remove these 2 lines and audio plays in Firefox
var sourceNode = context.createMediaElementSource(el);
sourceNode.connect(context.destination);

Here is the JSFiddle:
http://jsfiddle.net/marcoslin/Jb4LN/

If you click the game in the Fiddle results using Chrome, the sound will play. Music does not start in Firefox.

Here is a similar unanswered question.

+4
source share
1 answer

, , . , html, fx 25.0.1

: http://www.alianetwork.it/fx/

+1

All Articles