Detect image without curves

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
ethaniel
Posts: 5
Joined: 2015-04-22T15:46:32-07:00
Authentication code: 6789

Detect image without curves

Post by ethaniel »

Dear IM community, I've been banging my head against a wall for 6 months now.
I have a live beach camera which sometimes loses it's signal and produces a still image (which has no curves):
Image

This is a example of a good image:
Image

Is there non-expensive computing wise way of detecting the first image? (the camera is connected to a udoo board, which can barely pull the broadcast of the stream). The problem is that it always contains different colours (but the shape stays pretty much the same).

I am thinking that a good approach would be to count the number of curves in the image (but couldn't figure a way how to do it).
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Detect image without curves

Post by snibgo »

How often is an image captured? A good method might be to compare adjacent frames: if they are similar, they are both good, but if they are very different then at least one is bad.
snibgo's IM pages: im.snibgo.com
ethaniel
Posts: 5
Joined: 2015-04-22T15:46:32-07:00
Authentication code: 6789

Re: Detect image without curves

Post by ethaniel »

I tried comparing 2 frames, but sometimes there are variations in 2 "bad" frames which are higher than variations in 2 "good" night frames. So it's not a 100% optimal solution.
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Detect image without curves

Post by snibgo »

That's what we want. A small difference between two good adjacent frames, and a large difference between one good and one bad, or two bad frames.

If two adjacent bad frames have a small difference, then the test needs to be more complex.
snibgo's IM pages: im.snibgo.com
Post Reply