Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Daringescape

macrumors regular
Original poster
May 7, 2003
152
0
CA
I have a project I am working on where it would be helpful to be able to add black censor bars over the eyes of people in photos that are uploaded by users.

Does anyone have any ideas on how I may be able to do this without having to look at every image? I dont want the user to have to do it - I would like for it to be done automatically.

Is it even possible?
 
I have a project I am working on where it would be helpful to be able to add black censor bars over the eyes of people in photos that are uploaded by users.

Does anyone have any ideas on how I may be able to do this without having to look at every image? I dont want the user to have to do it - I would like for it to be done automatically.

Is it even possible?

As long as you have programmatic access to the image data, its possible.

Using as3 (flash) you would use the bitmapData class. You can do facial recognition in near realtime with a connected webcam.

I would *guess* you could do the same with PHP and an image library like imageMagick

Getting the content of the image is the easy part. The real challenge is finding (and tracking) the face. Read up on some facial recognition algorithms (partiicularly OpenCV) and see if there are any tricks you can use (most algorithms will be in higher level languages like C).

In some ways, capturing live data might be easier than from static images. With a live feed you can compare moving pixels against a known background (and known lighting) to identify the subject and then position the box relatively. In a static image you have a *lot* less to go on.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.