title: Which is the most efficient way to do alpha mask in opencv?
body: <p>I know OpenCV only supports binary masks.<br>
  But I need to do an overlay where I have a grayscale mask that specifies transparency of the overlay. </p>
  
  <p>Eg. if a pixel in the mask is 50% white it should mean a <code>cv::addWeighted</code> operation for that pixel with alpha=beta=0.5, gamma = 0.0.</p>
  
  <p>Now, if there is no opencv library function, what algorithm would you suggest as the most efficient?</p>