How do I automatically obscure my face when using video chat?
A paper bag?
I won't dwell on this too long but you want to video chat but not be seen? Seems a little odd and a little suspicious but anyway.
I don't think anything like what you want really exists but there are separate projects that:
- Do face detection and overlays in that space (OpenCV)
- A fake-webcam driver to turn a video source back into something that looks like a webcam to the system and therefore Empathy/Skype/ChatRoulette/etc (WebcamStudio)
Let's be clear, you're going to have to do a little bit of work here. It's not going to be a clean solution either. But if you want it, you can do it.
Webcamstudio has basic face detection but you can also use it to place an image anywhere on the screen. I'll go through both. I'll be using Ubuntu 10.10 with webcamstudio_0.57alpha2_all.deb available from their Google Code website
If you haven't done already follow the instructions for adding yourself to the video group as described here
Once installed open up webcam studio. You should have something like this
On the left-hand side, under Devices double-click on your webcam device. Click on Apply to get turn on your webcam in the software
From here we have two options for obscuring your face. The first is to place an image over the screen. In the left-hand panel under Animations click on the waving hand
Your screen should look something like this. Click on Play to apply the waving hand
If you want to try face detection, instead of adding the hand click on the webcam device and then in the Face Detection tab tick the checkbox and choose a face to use.
To see this in action open up a program that uses the webcam. For this example I'm using Cheese. In Cheese go to Edit > Preferences and change the webcam to the WebcamStudio Video Device
Here is the waving hand in action
And here's face detection in action
As you can see it doesn't work very well. I've asked on their mailing list for help on this matter but the response is that it's not very reliable and depends on lighting conditions and the quality of the camera.
There are other ways to obscure a video stream within that program but that's for another tutorial.
I don't think that it is practical to do any kind of real-time face-hiding like this. The algorithm that you use would have to accurately detect and hide your face perfectly in every single frame of video. If it fails to hide your face for even a single frame, then you've failed, and the other person has a picture of your face.
The problem is that because of the real-time requirement, you can't review the video and fill anything that was missed by the automatic face-hiding algorithm. You have to be able to trust this algorithm to get it right on its own every single time. I don't see how you can do that.
So yeah, I vote for Oli's paper bag. It reminds me of the (apocryphal but illustrative) story of American and Russian responses to discovering that pens don't work in space. The Americans invented a pen that does write in space (the pressurized ball-point pen), while the Russians switched to pencils.