hiukim / mind-ar-js

Web Augmented Reality. Image Tracking, Face Tracking. Tensorflow.js
MIT License
2.24k stars 417 forks source link

"Failed to launch" error #182

Closed underlabmx closed 2 years ago

underlabmx commented 2 years ago

A few days ago I realized that in multiple projects of mine and acquaintances the legend "failed to launch" appears, I thought it was the code but I realized that even internet examples present the same error, apparently the camera is not being activated , tried on several devices and browsers with the same result, does this happen to anyone else?

Example Screenshot_20220511-115724

Shackless commented 2 years ago

Same here on my Pixel 6 Pro while trying to connect to a webserver running on my desktop. If I launch the page on the desktop with a webcam connected, everything works fine. If I disconnect the camera, I get the same error, even on Desktop. So yeah, seems like the camera on mobiles is not activated correctly.

€: The official Demo page does work on my mobile though.

Shackless commented 2 years ago

@underlabmx My problem was that I was trying to access a the page via http on my mobile. Apparently, the site has to be served using https or Chrome won't let it access the camera at all. Deploying to Netlify or GitHub Pages solved it for me.

hiukim commented 2 years ago

Yes, it requires https to obtain the webcam feed.