before you ask yes I already saw this subject(What algorithm can be used for deflickering timelapse shots?)

The answer of Matt Grum is nearly what I'm looking for but I need more precision and I think I missed something.

First I wanted to know exactly how you can choose the threshold to account for the movement? (And what is exaclty the end of the first paragraph?

Secondly my pictures got a big black part wich is not affected by the flickering, would that kind of algorithm still be good?

Thank you


1 Answer 1


For the first part, it isn't talking about movement, it is talking about changes in exposure. The adjustment is determined by how much change has to be made to make part of one shot's luminance match that of the same part of the previous shot (since presumably they should look the same.) This can break down if there are shadows moving across the scene or the point changes though, so multiple points should be used to get an average or the point should be manually selected.

For the second part, as long as the darkest image can be used and the black is pure black, then bringing down darker images, the black will still be black. If you can't use the exposure of the darkest image, then you will need to use curves such to keep the black point consistent as you change the exposure on the way out. More simply, you could look for the darkest part of the frame and make sure that that is always black, though you may run in to issues related to the rate of change between the colors in between the brightest and darkest point since the dynamic range will be reduced on images that are overall darker and have to be brightened (thus having to make a medium grey black in order to keep the black point.)

Curves could be used to minimize this and you could use a statistical analysis of the % of the image at each luminance level to try to maintain the general luminance distribution, but depending on the changes in the scene, that might get unpredictable results since any kind of change in the amount of the scene covered by shadows would impact the luminance distribution as well, as would actual changes in light level.

  • \$\begingroup\$ And so why do we need to add the mean delta to the (i-1) luminance and what would mean the "and s"? \$\endgroup\$
    – Jimolrame
    Mar 5, 2014 at 16:27
  • \$\begingroup\$ @user3178283 - With a time lapse, you want the overall average luminance to be the same across the image. You figure out the average difference in luminance of all the pixels and then apply that average change to all of the pixels. This way the overall average luminance of one frame will be the same as the previous. I'm not sure about the "and s" part. \$\endgroup\$
    – AJ Henderson
    Mar 5, 2014 at 16:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.