I would like to dive into WebRTC, particular audio recording. So I tried this DEMO and the first problem arose: when I record in the latest Google Chrome I always hear a high-pitched buzzing sound in the background which is very annoying and probably not intended.
Is that a problem with my computer / settings or is this just normal? Because if this is ordinary, WebRTC is pretty useless for my purpose.
If this is related to my audio-midi-settings – here are some screenshots:
Goto source code and comment this line:
// __stereoAudioRecorderJavacriptNode.connect(context.destination);
Actually microphone is connected with speaker. This causes the recorded audio to be played back in the speakers.
Updated:
This workaround doesn't seems to be working. Sorry.
It was taken from here.
Related
For some reason, my Yahoo email tab sporadically plays audio from the beginning of an ad. The audio is definitely coming from this tab because it shows the small audio icon while it plays. I'm looking for some help using Chrome's Developer Tools. When I hear the audio clip, I have the Developer Tools open and I reference the [Network] tab, but I don't see any audio files referenced. I think it might be part of JavaScript. I'm looking for some guidance on how to isolate the source of the audio. Yahoo support was zero help.
Credit to #wOxxOm:
In DevTools, Sources, Event Listener Breakpoints, set breakpoints on all Media then wait till the sound is played or trigger it if you can. Then you should get some minified JS code, which you can pretty-print for easier reading, although the code is still minified and thus obfuscated so you have to kind of guess what it's doing. In my case, the code stopped on an ended event, but not on play. Still, I was able to find the code that actually played the sound - it went something like:
(h = e.play()) ? h.then(()=>{
a.Pa.info`Playing ${e.src}`;
a.ta = !0
}
and hovering over src (I could also have inspected e in that context to find src) showed me the URI for an mp3 that was the sound I was looking for! Breakpoints set on WebAudio did not work in this case - maybe it depends on the type of audio media being played? But I found the mp3 I was looking for! (Not saying what it was, but it was a very short clip - about 2 seconds - and as I understand it, samples below a certain length are not copyrightable, although I'm not 100% sure about that, so beware - as it is, I intend to use it for a personal, non-commercial project.
Follow these Steps to get the URL of the audio
Open the web page
Inspect the web page
Go to the Sources tab
Expand the Event Listener Breakpoints dropdown
Expand the Media dropdown
Mark the playing checkbox
I have a website, that should play mp3 files after clicking on a logo. When a sound is played, the p5.js library (p5js-sound) draws some graphic on the background. Suddenly it has stopped working. In the Chrome console log, the problem is with this line. Without any reason after two years of working properly, it started to give this error
Uncaught TypeError: this.audiocontext.createScriptProcessor is not a
function.
I found out that it works in Firefox and on some computers with older versions of Chrome. How to solve this problem?
Newest versions of Chrome will not "autoplay" audio. Some kind of user interaction is required, ie. click on something to "start" the audio context. When I get it to work I will post code.
It is unlikely that this is a problem with your code or anything you have done to the p5.sound library.
On the contrary, it may be an out-of-date version of the library and the processing foundation may not have updated it yet. They are a non-profit organisation so cut them some slack but I suggest using an alternative library for now
You could use native functions like an onclick="" that controls whether a hidden <audio></audio> tag is playing - Good luck coding!
I have a site which has a collection of audio clips for voice actors to promote their skills and talents. Recently it has been brought to my attention that in Google Chrome some of the clips do not play. However you can download the .mp3 and it will play fine, or you can listen to it fine in Firefox, Safari, IE, etc.
So I started Googling and found this bug which was closed a couple of years ago: https://code.google.com/p/chromium/issues/detail?id=110309
I also found this page: http://cro.ma/?faqs=some-of-my-mp3-files-does-not-play-in-google-chrome-browser-but-works-fine-in-all-other-browsers
The MP3 in question is fairly short 10s in playtime, and only 168kb in size. It did have some meta information there but as recommended in the link I stripped that off, however it still doesn't play.
The only other difference I have noticed between the non-working MP3 and the working MP3s is that the non-working one has a bit rate of 112kbps, whereas the working ones are 128kbps.
The site uses MediaElement.js but even just dragging the MP3 into the browser window and using the default engine has the same outcome.
Has anyone else experienced this issue and know of a fix?
It's a problem with version 45 of Google Chrome. Joshua Moon has provided the following solution which may help you, all credits go to him. Just posting as your question was asked after his and I thought you might not have seen it.
Joshua said:
I'm not 100% on the specifics of this, however, it looks like some MP3s using older versions of Lame, or longer than a couple of minutes, or at high (300 <) or low (128 >=) bitrates seem to be affected. It appears to be webkit-related, as it also affects Safari users.
HOWEVER!
As a solution, re-encoding the MP3 files using 160Kbps bitrate, and the latest version of LAME (3.99.5) seems to have fixed this, and they now play normally across all major browsers again.
You can see the full question and answers here (on Stack Overflow): Google Chrome no longer plays certain audio files
I had this problem today on Chrome 50 and simply restarting my browser got it working again.
Based on other's comments I installed "Audio Converter" and converted my mp3 files to 128 Kbps (standard) and they now work. I don't find any loss of quality.
I have a weird issue in Chrome.
Each time I load a <video> element, chrome will start two HTTP request.
The first one will stay pending forever (I guess this is the "meta-data", "partial content" request. But the point is that it stay pending)
The second one to the same file is ok and goes on and close after the loading is over.
The problem here is that the first request stay pending until I close the browser page. So at some point, if I load multiple video, Chrome will break and stop downloading anything because every available request is occupied by these pending requests.
I created a reduced test case here: http://jsbin.com/ixifiq/3
I've check to reproduce the issue, and it is happening on both Video.js and MediaElements.js frontpages. Open your network tab when loading the page, you'll see the first pending request. Then press play on the video, and you'll see the second request working, but the first one will stay pending forever.
Does anyone knows a fix to this bug?
(This bug still exists in Chrome 38.0.2125.111, OS X 10.10)
This may be a Chrome bug & you may solve it without any dummy ?time-suffix trick, just helping Chrome releasing sockets faster:
I had the same bug on a RevealJs HTML presentation, with 20+ videos (one per slide, autoplayed on slide focus). As a side effect, this unreleased socket problem also affected other ajax-lazy-loaded medias following immediately the first pending/blocked video, in the same HTML DOM.
Following Walter's answer (see bug report), I fixed the issue following the next steps:
1- Set video preload attribute to none:
<video preload="none">
<source src="video.webM" type="video/webM">
</video>
2 - Use a canplaythrough event handler to play and/or pause the video once it is loaded & ready. This helps Chrome releasing the socket used to load that video :
function loadVideos(){
$("video").each(function(index){
$(this).get(0).load();
$(this).get(0).addEventListener("canplaythrough", function(){
this.play();
this.pause();
});
});
}
Apparently that's a bug from Chrome. And there's nothing to do about it ATM.
I reported the issue a while ago on the Chromium project and it's been assigned. So hopefully it'll be fixed in near future.
Bug report: https://code.google.com/p/chromium/issues/detail?id=234779
I don't know if it will be functional right now, but I remember solving this issue by adding a parameter to the video URL, just like "video.mp4?t=2123". Of course, everytime you load the video, the parameter should be different. I'd use
var parameter = new Date().getMilliseconds();
to get it, and add it.
With this, at least a few months ago, I was able to play the same video multiple times without Chrome waiting forever the response.
Hope it helps.
This bug still exists. I'm using an HTML5 video player on a single page application. After loading about 7 players with pre-buffering, I hit the limit and no more videos load. I found another answer having to do with images and I was surprised to find that this answer solves this problem.
if(window.stop !== undefined) {
window.stop();
} else if(document.execCommand !== undefined) {
document.execCommand("Stop", false);
}
reference: Javascript: Cancel/Stop Image Requests
I found this issue when using html5 video inside dynamic content such as carousels, to release the blocked sockets you have to unload the video source:
var video = $('#video');
video[0].pause();
video.prop('src','');
video.find('source').remove();
video.remove();
The bug claims to be fixed but I still had to do this on Chrome 42. At least I could still set preload="auto".
We had the same symptoms, but the problem was that we were calling load() on the same video twice in succession: same video control, same video source (MP4). Two identical 206 requests showed up in the dev tools, and then, after switching video a few times, Chrome would cancel the first request, turn off progressive playback, and wait for that second request to complete.
Also note that if you're using an MP4 source and it isn't formatted for progressive playback (meaning the MOOV atom is at the beginning of the file), then you will have 1-2 additional requests for the file, which makes it even more confusing.
#sidonaldson 's answer is the only one that worked for me. However I did not remove the video or source. The following code worked for me, run this just before putting the correct src and playing it.
const video = document.getElementById('player')
video.pause()
video.setAttribute('src', '')
video.load()
#ecropolis's answer also worked but my SPA would end up having no images so it was not an option.
I'm currently working on a flash game and, at least on my machine, the audio seems to lag by a fraction of a second in Chrome, but not in IE or FF. This isn't a huge deal, the game is still playable, but it's a little bit annoying. Is there anything I can do from a development standpoint to fix this issue or is it something the user would have to fix?
Edit: I've now tested it on two other machines and the same thing happened. The audio is delayed in chrome but not Firefox or IE.
Edit 2: I've also tried the same thing in a few popular games on Newgrounds to the same effect. Is this just something wrong with Chrome?
Edit 3: I tried lowering the bit rate of the audio from 44kHz to 22 and it didn't do anything to fix it. (It also sounded terrible, predictably)
Edit 4: To prove it's not a memory management problem I created a blank SWF that just plays an audio file on mouse click, it also has the lag issue. This is definitely not a Flash or AS3 isolated issue.
I have/had the same problem with Chrome.
if you go to: chrome://plugins (->details) and disable PepperFlash, then it runs smooth. Not sure if Pepper is the default for Chrome, or if its the particular version of flash we installed.
C:\Users\ [USERNAME] \AppData\Local\Google\Chrome\Application\21.0.1180.75\PepperFlash\pepflashplayer.dll
I had an intermittent audio and then the video started to lag. The solution was two fold:
Re-install chrome.
Get the latest Adobe Flash Player.
I had to do both things for it work properly. To get the plugins type the following in chrome address bar: chrome://plugins
After you install the latest player you need to disable the older one.
Hope this resolves your problem as it did for me.