An extension that puts masks on faces on the internet (only works on Chrome).
Beware: This extension is a proof of concept and really slows down your browser (and also destroys several sites).
https://twitter.com/moklick/status/1234421465287680000
In order to try the extension you can load the unpacked version in your Chrome browser by following these steps:
- Download or clone this repository
- Type
chrome://extensions
in the address bar - Enable the
Developer Mode
switch in the top right corner - Click the
Load Unpacked Extension…
utton - Select the directory
extension/chrome
of this repository
- Check site for images and wrap them with a div
- Observe these wrapped images with IntersectionObserver
- When an image appears in the viewport, check if there are faces on it using face-api
- If there are faces add a canvas to the wrapper and draw the masks with this drawMask function
You need Node.js in order to modify this extension.
npm install
npm run dev:chrome
- 🙌 Bjorn Stromberg for his very helpful contributions to this extension
- The code is based on the great web-extension-starter by Abhijith Vijayan