web-audio-api

Release audio Buffer Web Audio API

女生的网名这么多〃 提交于 2019-12-01 14:29:53
I'm using WEB Audio API for a Webapp to render an Audio Signal. But, I have a problem, being loading an audio file each second, chrome use more and more RAM and I have no idea how to release buffers / sounds that I no longer need. Is there any way to solve my problem from my javascript program or changing chrome propieties? My code: loadSounds(this, { buffer: this.url }); function loadSounds(obj, soundMap, callback) { // Array-ify var names = []; var paths = []; for (var name in soundMap) { var path = soundMap[name]; names.push(name); paths.push(path); } bufferLoader = new BufferLoader(context

Release audio Buffer Web Audio API

淺唱寂寞╮ 提交于 2019-12-01 13:18:48
问题 I'm using WEB Audio API for a Webapp to render an Audio Signal. But, I have a problem, being loading an audio file each second, chrome use more and more RAM and I have no idea how to release buffers / sounds that I no longer need. Is there any way to solve my problem from my javascript program or changing chrome propieties? My code: loadSounds(this, { buffer: this.url }); function loadSounds(obj, soundMap, callback) { // Array-ify var names = []; var paths = []; for (var name in soundMap) {

SoundCloud Api redirect confusion and Audio Api Streams

喜夏-厌秋 提交于 2019-12-01 13:01:42
I am attempting to make a request to the SoundCloud API. Then when I get the response I set the stream_url as the source of an < audio > element. This works: http://matthiasdv.org/beta/ But not always... When you search for 'Bonobo' for example, you can play the first few tracks without any issue. But when you try to play 'London Grammar - Hey Now (Bonobo remix)' - the 7th result - it won't play. It throws no errors whatsoever. I've been tinkering around with Chrome's webdev-tools and under the network tab I see the requests being made. I found that tracks that DO play have a short Request Url

Desktop Audio Capture Not working for chrome app

£可爱£侵袭症+ 提交于 2019-12-01 11:19:44
问题 According to https://code.google.com/p/chromium/issues/detail?id=223639 chromium has issues with audio Loopback. and it never works in chrome app. Can anyone share some links and explanation to why is this not working?Or if it is possible? I tried below code but lot of disturbance in desktop audio. video: { mandatory: { chromeMediaSource:'screen', chromeMediaSourceId: id } }, audio: { mandatory: { chromeMediaSource: 'system', chromeMediaSourceId: id, } } Multiple streams are captured and

Web Audio API no sound playing

爱⌒轻易说出口 提交于 2019-12-01 08:03:02
I'm trying to get into the Web Audio API as I'm looking to make some visualizations based on the music that's playing. However all examples I have found, it's like the audio is muted. It plays the file but there's no sound. For example: codepen.io/noeldelgado/pen/jqibm Even following this - https://www.youtube.com/watch?v=IBHpSkGZtNM yields same result. I'm on mac, using the latest version of Chrome (42.0.2311.90), have also tried on latest Firefox and it's the same problem. It's a cross-origin access issue in createMediaElementSource that landed in Chrome 42. You need to setup the appropriate

Web Audio API no sound playing

孤街浪徒 提交于 2019-12-01 07:14:19
问题 I'm trying to get into the Web Audio API as I'm looking to make some visualizations based on the music that's playing. However all examples I have found, it's like the audio is muted. It plays the file but there's no sound. For example: codepen.io/noeldelgado/pen/jqibm Even following this - https://www.youtube.com/watch?v=IBHpSkGZtNM yields same result. I'm on mac, using the latest version of Chrome (42.0.2311.90), have also tried on latest Firefox and it's the same problem. 回答1: It's a cross

webaudio not working with ionic using crosswalk on android device

蹲街弑〆低调 提交于 2019-12-01 07:03:38
I created an ionic webrtc app that runs perfectly when using ionic serve (on web browser, witch is normal). but was not working at all on the device since the getUserMedia function was not able to execute. The solution i found is to install crosswalk, update permissions in the AndroidManifest.xml and add the meta tag on the index.html for content security: <meta http-equiv="Content-Security-Policy: media-src: 'self' mediastream"> Now, i have a working ionic webrtc app but only video, the audio is not working. the android app is able to diplay video with its audio, but seems to only send video

Why certain .wav files cannot be decoded in Firefox

陌路散爱 提交于 2019-12-01 05:52:07
I have a web page which decodes wave files for certain reasons. Chrome and Safari seem to work fine. Firefox occasionally is unable to decode the file and gives the error: "The buffer passed to decodeAudioData contains invalid content which cannot be decoded successfully." I have created a jsfiddle which illustrates the issue: var audioCtx = new (window.AudioContext || window.webkitAudioContext)(); var source; function getData() { source = audioCtx.createBufferSource(); request = new XMLHttpRequest(); request.open('GET', 'https://mpclubtest.s3.amazonaws.com/Malice_Bass.wav', true); request

Web Audio API analyser node getByteFrequencyData returning blank array

ぐ巨炮叔叔 提交于 2019-12-01 05:23:50
问题 I'm trying to access FFT data from the analyser node using analyser.getByteFrequencyData(array) but it seems to return a blank array: var array = new Uint8Array(analyser.frequencyBinCount); analyser.getByteFrequencyData(array); However using analyser.getFloatFrequencyData(array) returns an array of data: var array = new Float32Array(analyser.frequencyBinCount); analyser.getFloatFrequencyData(array); I'm using a signal chain as follows: Source -> Analyser -> ScriptProcessor -> Context

WebRTC mix local and remote audio steams and record

痞子三分冷 提交于 2019-12-01 04:35:37
问题 So far i've found a way only to record either local or remote using MediaRecorder API but is it possible to mix and record both steams and get a blob? Please note its audio steam only and i don't want to mix/record in server side. I've a RTCPeerConnection as pc . var local_stream = pc.getLocalStreams()[0]; var remote_stream = pc.getRemoteStreams()[0]; var audioChunks = []; var rec = new MediaRecorder(local_stream); rec.ondataavailable = e => { audioChunks.push(e.data); if (rec.state ==