Hi, so I’m having a bit of trouble implementing a system that can detect night and day through webcam.
I’ve decided the best approach would be to detect the average colour of the webcam image, and through this it can be converted to grayscale and if its closer to black the background will be dark or if its white it’ll be brighter.
What I’m having trouble doing is working out how to achieve this, I’ve been using the kirupa webcam tutorial but I’ve got no idea how to actually go about working out the average colour.
http://www.kirupa.com/flash/getting_started_with_the_webcam.htm
I’ve seen a tutorial that actually applies filters to the webcam image so manipulating the webcam is possible.
Anyone want to give us some help? It would be much appreciated.