Slashdot Mirror


Firmware Hack Allows Video Analysis On a Canon Camera

An anonymous reader writes "Researchers from the University of Liege in Belgium have been able to perform real-time video analysis on a regular Canon digicam (video link) without any hardware modification. The results are shown directly on the digicam's screen. They use a hacked version of a popular open-source alternative firmware for Canon cameras: CHDK. This is a proof-of-concept that computer vision algorithms can now be embedded on regular Canon digicams with little effort (CHDK is coded in C). What other popular vision algorithms could be implemented? For what purpose?" You can get some idea about ViBe from this abstract at IEEE; basically, it allows background extraction in moving images.

30 of 115 comments (clear)

  1. Zoneminder by b0bby · · Score: 2, Interesting

    I've been playing around with Zoneminder a bit & this could be a way to use decentralized cheap cameras to send events to a ZM server. Pretty neat.

    1. Re:Zoneminder by davester666 · · Score: 3, Funny

      I wrote code for this so that my camera would draw a little red box around the faces of terrorists. It seems I'm surrounded by them.

      --
      Sleep your way to a whiter smile...date a dentist!
  2. CHDK by The+MAZZTer · · Score: 4, Informative

    I use CHDK on my own Canon PowerShot. Good stuff.

    1. Re: CHDK by 0100010001010011 · · Score: 2, Interesting

      What's the 'newest' Camera that supports CHDK? Mine got stolen recently and I'd like something to replace it for times I don't want to lug around my SLR.

      Does CDHK support the DIGIC IV (720p, better face recognition). I played around with one of my friends and face recognition, the fact that you can zoom in and scroll through all faces to make sure they're in focus. Lots of cool stuff, but CDHK seems to mostly support older stuff and Canon's numbering scheme sucks.

    2. Re: CHDK by rhizome · · Score: 2, Informative

      Check the sidebar: http://chdk.wikia.com/wiki/CHDK

      I'm anxiously awaiting the SD1200 port.

      --
      When I was a kid, we only had one Darth.
    3. Re: CHDK by kimvette · · Score: 3, Informative

      I use it on my S5 IS. I use the intervalometer, various grids (for composing level shots when it matters), the extended shutter modes (both slower and faster than the "stock" firmware allows) and of course the RGB histogram and on rare occasion raw. I don't use raw too often though because it slows the camere down a fair bit. However, CHDK is a wonderful tool and scripting it isn't too bad. The documentation is actually pretty good for a "young" open source project. In short, it makes point-and-shoot cameras usable where they otherwise wouldn't be, and where a point-and-shoot camera is preferable to a DSLR (such as when traveling), it can give you some of the capabilities you would normally turn to a DSLR for.

      I hope they manage to port it to the DSLRs, particularly the EOS 7D.

      --
      The Christian Right is Neither (Christian nor right). See: Matthew 23, Matthew 25, Ezekiel 16:48-50
    4. Re: CHDK by xxdinkxx · · Score: 2, Insightful

      http://orbi.ulg.ac.be/bitstream/2268/12087/1/Barnich2009ViBe.pdf There is the paper in question. I despise the fact that I still have to pay for papers in IEEE silos when I am in fact a member.
      Yeah I could upgrade my subscription, but bah.

      RANT.YML
      rant:
      information should be free

    5. Re: CHDK by Anonymous Coward · · Score: 4, Funny

      What's the 'newest' Camera that supports CHDK? Mine got stolen recently and I'd like something to replace it for times I don't want to lug around my SLR.

      I'm interested by that too as I've recently "acquired" a new camera.

    6. Re: CHDK by TubeSteak · · Score: 2, Interesting

      I played around with one of my friends and face recognition, the fact that you can zoom in and scroll through all faces to make sure they're in focus.

      Maybe someone can explain the multi-focus thing to me.
      Does the camera pick out all the faces and then pick an average focal point?
      Or does the software (as opposed to the lens) actually tweak each face into focus?

      --
      [Fuck Beta]
      o0t!
    7. Re: CHDK by Anonymous Coward · · Score: 2, Informative

      Does repeating a link in the summary really count as informative?
      I know this article is only tangentially about CHDK but I've been looking into CHDK lately for a project so I thought I'd share some useful links.

      Supported Cameras

      Note that a higher number doesn't mean it's a newer model. The A710 was released before the A590.
      Canon PowerShot A series info

      CHDK Howto

      Info on how to make a port

      Info on implementing PTP in CHDK
      This is still relatively new but it could allow using a computer to remotely control the camera, which isn't doable on many Canon cameras with the stock firmware. I'd love to see this mature so I can do remote capture in Linux.

    8. Re: CHDK by Trebawa · · Score: 2, Informative

      I have a PowerShot SX200, which is compact and DIGIC IV. It also shoots 720p. There's a beta of CHDK for it, and it's worked well so far.

    9. Re: CHDK by DZign · · Score: 2, Informative

      As far as I know it'll check the different faces and decide where it has to put focus and a small enough aperture so
      they all are sharp.
      So if the faces are close enough to each other it can focus on one and go for a small dof that'll have them all sharp, if they're further away then it'll increase dof (and thus exposure time) and possible put actual focus somewhere in between the faces (again, if I'm not mistaken it's around 1/3 before your focal point and 2/3 after it that's sharp).

    10. Re: CHDK by vegiVamp · · Score: 2, Funny

      "acquired", with quotes ? What, you were taking an innocent evening stroll through a random stranger's living room and one just happened to fall into your pocket of it's own accord ?

      --
      What a depressingly stupid machine.
  3. Interesting... by fuzzyfuzzyfungus · · Score: 3, Interesting

    What I find interesting about this is not so much that the code can be loaded(since the CHDK project already did that job, and has had it working for some time now); but that consumer digicams would have enough general purpose punch to run anything much more than trivial scripts that more or less emulate series of button presses(which can be extremely useful, for time lapse, auto bracketing, etc, etc.).

    Given the sheer number that are produced, and the fairly tight battery life constraints, I would have assumed that most of the heavy lifting(crunching raw sensor data to .jpeg form, or encoding video) would be done with largely fixed function hardware, with just a little bit of general purpose computer slapped on to handle UI, user input, and tweak the settings of the encoder units. Apparently, the general purpose units have more punch than I thought.

    1. Re:Interesting... by vlm · · Score: 3, Insightful

      What I find interesting about this is ... that consumer digicams would have enough general purpose punch to run anything much more than trivial scripts

      Check the feature list of typical modern "consumer"-ish digital cams. Marketing has decided that the average moron needs to be able to filter pics to look like a faded photograph, or put the picture inside an ornate picture frame, or cover up parts of the image with heart and caption overlays like those stupid "reality-TV" dating shows. The enormous resources required for stupid marketing tricks can be re-purposed to do much more interesting things... Which probably pisses off the marketing guys. Which I like.

      To a first approximation, the computing power required to store a pic is not much worse than the viewfinder display. And they don't seem to care about updating the video viewfinder continuously. So, it can't be too horrible of a computational task.

      --
      "Science flies us to the moon. Religion flies us into buildings." - Victor Stenger
    2. Re:Interesting... by timeOday · · Score: 4, Insightful

      The most computationally demanding onboard processing I've noticed (aside from video encoding, which surely uses a dedicated chip) is recognizing multiple faces in real-time, or tracking a moving object, to maintain focus. Far from the gimmicks you mention, these are very useful functions that just happen to require what amounts to video processing.

  4. Re:Video analysis by Anonymous Coward · · Score: 2, Informative

    I'm sure "video analysis" means something more concrete to those in the know (or not), but I can't shake off the feeling that it's all blahblahblah with no meaning other than to generate more blahblahblah.

    OpenCV
    Integrating Vision Toolkit

    Think these libraries but on the camera. You take an image, you process HSV, contrast, and a bunch of other data to do shape detections, motion detection, etc.

  5. Re:THEY ARE NOT CALLED "DIGICAMS". by Mike+Buddha · · Score: 3, Informative

    I call it a Cami-DigiCam Camcorder. It's so important to get the terminology right when you don't know anything else.

    --
    by Mike Buddha -- Someday the mountain might get him, but the law never will.
  6. Why Bother Rewriting the Wheel? by eldavojohn · · Score: 2, Interesting

    OpenCV has C interfaces and there are more that have some C code libraries. Really the coding challenge would be building the wrappers to utilize those libraries with your camera's hardware (I assume provided through CHDK APIs). My vote is for a nifty KLT implementation that allows me to take a video and extract a huge wide pan image in post processing on the camera.

    --
    My work here is dung.
  7. Re:Video analysis by oldhack · · Score: 2, Funny

    I told you not to waste time on slashdot again. You on my list, now.

    --
    Fuck systemd. Fuck Redhat. Fuck Soylent, too. Wait, scratch the last one.
  8. Re:Thank you, Lord of Language by spun · · Score: 2, Funny

    Digicam is a perfectly cromulent word. You may want to look into the prescription/description debate to understand everyone thinks you are a ridiculous buffoon.

    Also, I resent the implication that I ride a Harley.

    --
    - None can love freedom heartily, but good men; the rest love not freedom, but license. -- John Milton
  9. Not alternative firmware by marcansoft · · Score: 5, Informative

    It's worth pointing out that CHDK isn't a hacked firmware (that would probably not be legally redistributable), nor is it an alternative firmware (that would be too much work). CHDK is an add-on to the existing firmware, that works by piggibacking on its OS, hooking functions, and spawning off extra processes on the camera's RTOS. This is what makes it so great: you get the original funcionality of the camera plus extra stuff, and you don't have to wait for the developers to add what already came with your camera anyway.

    1. Re:Not alternative firmware by Anonymous Coward · · Score: 2, Interesting

      CHDK is an add-on to the existing firmware, that works by piggibacking on its OS

      If it would have been an Apple camera, ten thousand lawyers would have been busy suing the developers.

      CHDK made me buy a Canon, and Canons approach of "live and let live" will make my next purchase a Canon 50D.

      Thank you Canon!

  10. Re:Fun idea by ClosedSource · · Score: 2, Insightful

    If you need an algorithm to identify which girls are attractive, then you don't need an attractive girl.

  11. Re:THEY ARE NOT CALLED "DIGICAMS". by timeOday · · Score: 3, Insightful

    Right, the new word for "digital camera" is "camera." If you mention to a friend that your camera battery is dead, would they still ask whether you can advance the film manually? No. The vast majority of cameras made, sold, and used today are digital cameras, so that is what the word has come to mean.

  12. Re:For SLR's makes much more sense by SharpFang · · Score: 2, Informative

    Because they are SLRs. Their firmware can do almost all CHDK can do. A lot of work and little gain, plus risk of bricking an expensive camera. The main focus of CHDK is cheapest idiotekameras, because the difference it makes is really huge.

    --
    45 5F E1 04 22 CA 29 C4 93 3F 95 05 2B 79 2A B2
  13. If you are interested by testing ViBE... by Anonymous Coward · · Score: 2, Informative

    You can check our dedicated webpage.

    It features downloadable binaries for windows and linux (thanks to wine).

  14. Re:THEY ARE NOT CALLED "DIGICAMS". by maxwell+demon · · Score: 2, Informative

    Isn't this when somebody is supposed to chime in with a meme?

    In Korea only old people use film?
    In Soviet Russia film uses you?
    Or maybe just imagine a Beowulf cluster of hacked Canon cameras ...

    --
    The Tao of math: The numbers you can count are not the real numbers.
  15. Re:Canon S90 by bograt · · Score: 2, Informative

    I just checked the tripod mount on my S90, and it looks like it's smack bang in the centre of the lens.

    As for the pop-out flash, it's motorised. I don't know if that makes it more os less robust, but there you go.

    I've read that the S90 is basically the same as the G11 but with a different body and lens, which gives me hope that CHDK will be available for the S90 soon, since it already is for the G11. It does shoot RAW out of the box, though. You won't need CHDK for that.

  16. Re:THEY ARE NOT CALLED "DIGICAMS". by Khyber · · Score: 2, Informative

    No, most photographers that refer to a non-SLR digital camera refer to it as a PnS (Point and Shoot) and dSLR as just "SLR" as in most digital forums it's automatically assumed you're running a digital camera opposed to film.

    I still take superior pictures with my Minolta X-700, no Photoshop needed afterwards.

    --
    Still waiting on Serviscope_minor to wake up to fucking reality and realize that Jessica Price isn't going to fuck him.