qiuxiang / tuner

Online tuner based on web audio api
https://qiuxiang.github.io/tuner/app/
MIT License
334 stars 122 forks source link

Doesn't run when I open in local file #13

Open gunshire opened 3 years ago

gunshire commented 3 years ago

Hello. My issue is: I have downloaded your code in a .zip file, I'm trying to test it but it won't work when I open the index.html, it does not even ask for permission to use my microphone. I have other projects in my PC using "getUserMedia"/JavaScript that run normally, I don't understand what the issue is.

image

qiuxiang commented 3 years ago

Because the pitch detection library aubio.js needs to fetch aubio.wasm, but fetch API not supported with local file.

Screenshot from 2021-08-20 17-05-03

MX-Qulin commented 3 years ago

2021年8月20日 10:06,7c00 @.***> 写道:

Same as #12 https://github.com/qiuxiang/tuner/issues/12. u need https server.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/qiuxiang/tuner/issues/13#issuecomment-902354323, or unsubscribe https://github.com/notifications/unsubscribe-auth/AJOOJ5OTZVMF5EF3M4PT7G3T5WTBNANCNFSM5COBL4DQ. Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email.

Hmmm, then you need to run it on a server and you’ll have to get a ssl certificate because no modern browsers allow getUserMedia on unsafe sites.