title: OpenCV floodfill with mask
body: <p>The <a href="http://docs.opencv.org/modules/imgproc/doc/miscellaneous_transformations.html#floodfill">documentation</a> for OpenCV's floodfill function states:</p>
  
  <blockquote>
    <p>The function uses and updates the mask, so you take responsibility of
    initializing the mask content. Flood-filling cannot go across non-zero
    pixels in the mask. For example, an edge detector output can be used
    as a mask to stop filling at edges. It is possible to use the same
    mask in multiple calls to the function to make sure the filled area
    does not overlap.</p>
  </blockquote>
  
  <p>How does the function update the mask?  Does it set all the pixels within the floodfill to some non-zero value?</p>