title: Detection of objects in nonuniform illumination in opencv C++
body: <p>I am performing feature detection in a video/live stream/image using OpenCV C++. The lighting condition varies in different parts of the video, leading to some parts getting ignored while transforming the RGB images to binary images.</p>
  
  <p>The lighting condition in a particular portion of the video also changes over the course of the video.  I tried the 'Histogram equalization' function, but it didn't help.</p>
  
  <p>I got a working solution in MATLAB in the following link:</p>
  
  <p><a href="http://in.mathworks.com/help/images/examples/correcting-nonuniform-illumination.html" rel="nofollow">http://in.mathworks.com/help/images/examples/correcting-nonuniform-illumination.html</a></p>
  
  <p>However, most of the functions used in the above link aren't available in OpenCV.</p>
  
  <p>Can you suggest the alternative of this MATLAB code in OpenCV C++?</p>