chord_detector icon indicating copy to clipboard operation
chord_detector copied to clipboard

Demo in mobile dorsnt work.

Open cambo2015 opened this issue 6 years ago • 2 comments

Hey cool project. I tried to get the demo working on my phone but it doesn't seem to work, at least for me. Is it just the demo/phone? Would love to use this library in the future.

cambo2015 avatar Oct 15 '19 13:10 cambo2015

I noticed this too. It works fine for me in a desktop browser, but it only partially works on an Android browser. It registers changes volume, but it just doesn't detect notes. Maybe it's something with the weird/special speakers used in phones?

chrisspen avatar Jan 16 '21 00:01 chrisspen

I've managed to get it partially working in mobile by adding these audio constraints to the call for navigator.mediaDevices.getUserMedia:

echoCancellation: false,
noiseSuppression: false,
autoGainControl: false

I suspect that on mobile browsers they usually default to having these enabled, which probably helps voice audio but destroys the fidelity of musical pitches.

Unfortunately, it's still a little off for me. It's showing the pitch as being exactly one note off from what my tone generator makes.

chrisspen avatar Jan 17 '21 21:01 chrisspen