title: How to create a semi transparent shape?
body: <p>I would like to know how to draw semi-transparent shapes in OpenCV, similar to those in the image below (from <a href="http://tellthattomycamera.wordpress.com/" rel="noreferrer">http://tellthattomycamera.wordpress.com/</a>)</p>
  
  <p><img src="https://i.stack.imgur.com/JQ77M.png" alt="enter image description here"></p>
  
  <p>I don't need those fancy circles, but I would like to be able to draw a rectangle, e.g, on a 3 channel color image and specify the transparency of the rectangle, something like</p>
  
  <pre><code>rectangle (img, Point (100,100), Point (300,300), Scalar (0,125,125,0.4), CV_FILLED);
  </code></pre>
  
  <p>where <code>0,125,125</code> is the color of the rectangle and <code>0.4</code> specifies the transparency.
  However OpenCV doesn't have this functionality built into its drawing functions. How can I draw shapes in OpenCV so that the original image being drawn on is partially visible through the shape?</p>