Face detection is a perfect example of what should be a plugin. I'm not saying it has to be a horrible old school NPAPI plugin. It could be a sandboxed app, it could be a WebAssembly library, and so on.
Edit: nothing against the OP's post, it's probably cool although I cannot test it on this PC :-)
Surely things like that, or a src attribute for csv files, or even rudimentary charts and graphs for tables don’t even get considered.
Suppose fixing 20year old issues just aren’t as sexy as usb access from the browser...
As time goes on I connect less and less with browser developers.
Totally agree on the technical side, let alone the privacy violation issues when Joe User leaves it running with the camera facing his bed, or someone asks me to do some maintenance to his pc/browser/whatever and after 5seconds a server somewhere knows I was there. I'm free to avoid that stuff, but I can't force users to do the same, and unfortunately most users will leave it on. If the technology phones home uploading associations between captured images, then we're back to Facebook square one, just without Facebook.
Want to make it safer? Leave it outside the browser, off by default at every session, and keep all data local. Contrary to popular belief, writing software that does not go online is not a crime.
Disclaimer: I could not try it because my browser luckily isn't supported, however to me it's pretty easy to foresee possible abusive/malicious uses of face recognition should it come as a standardized always on asset in a browser. Just think of Flash.
OTOH, face detection can be trivially done with OpenCV, and probably in WebAssembly, so there is no need to ship this in the browser core.
If you can’t see well and so enable VoiceOver, when a webpage opens the camera to take a photo the phone will what it sees, “like face in centre of photo”.
It’s very usefully for blind of partially sighted people to take selfies.
Here is a reference: https://www.apple.com/uk/accessibility/iphone/vision/
Edit: added link