title: How to set ROI in OpenCV?
body: <p>I have two images, the first one smaller than the other. I need to copy the second image on the first image. To do so, I need to set the ROI on the first one, copy the second image onto the first one and then reset the ROI.</p>
  
  <p>However I am using the C++ interface so I have no idea how to do this. In C I could have used cvSetImageROI but this doesn't work on the C++ interface.</p>
  
  <p>So basically whats the C++ alternative to cvSetImageROI?</p>
  
  <pre><code>//output is a pointer to the mat whom I want the second image (colourMiniBinMask) copied upon
  Rect ROI (478, 359, 160, 120);
  
  Mat imageROI (*output, ROI);
  
  colourMiniBinMask.copyTo (imageROI);
  
  imshow ("Gravity", *output);
  </code></pre>