Log in

View Full Version : Challenging anti-flicker problem


Ferux
20th February 2007, 14:38
I'm capturing home video's which were made by an analog camera. For some reason, in every 4 frames this camera recorded, the first one was darker and the second one brighter. This results in flickering when watching the video.

I tried anti-flicker filters as Antiflicker, Deflicker and even deinterlaced an entire 3h-video with MVBob, but these filters don't solve the problem.

With ApplyEvery I reached a solution:

JDL_SimpleApplyEvery("tweak(sat=1.25)",4,"1")
JDL_SimpleApplyEvery("tweak(sat=0.9)",4,"2")

This brightens the first, darker frame of every 4 and darkens the second, brighter frame of every 4. The result is very good, but the point where the 4 frames start to count, is different in every cut since it was caused by the camera.

The solution is probably implenting a scene-change detection and then by every scene change applying this filter 4 times, each time with a different starting frame, and then something has to find out which of the 4 possibilities gives the good result.

Does anyone have an idea to implent this? Or maybe another way to search which is the darker/lighter frame of the 4?


Many thanks on beforehand.

Ferux

Didée
21st February 2007, 13:00
It probably wouldn't be too difficult to create a script that does the correction automatically. However you should provide a short sample of the source (preferably a 'static' scene without motion), since the real problem is not fully clear:
You state that there is a problem with brightness, but your manual fix works with saturation. Now, which color has the wind?

For a working solution, the exact kind of deviation must be known. Poking in the blue won't work out.

Ferux
22nd February 2007, 13:53
I think the problem is saturation, but i'm not an expert. Here is a short clip, I didn't find a static one because during these home videos the camera moves all the time. You can see the flickering clearly on the handgloves of the child:

http://users.telenet.be/maaistro/doom9.avi

It's the original source, with one filter applied: securedeint. One can also see the flickering without a deinterlacer, but I want 50 fps.

Thanks!

Ferux
6th March 2007, 15:37
up? :o

Pookie
6th March 2007, 20:58
Greyscale() to determine if the luma is being affected (I don't think the luma is affected)

The intensity of the Blue and Red channels cycles every several frames.

How to fix ? What's wrong with B&W video everyone once in a while ?:D