title: How to extract simple geometric forms from contours in opencv
body: <p>I have a <code>Mat contours</code> and I have approximated each <code>contour</code> with <code>approxPolyDP</code>.
  What I want to do now is detecting forms like rectangle, triangle, circle. And e.g. redraw them in a different color or using canvas etc.</p>
  
  <p>Is there a way of making use of the contours? How can I access points in <code>Mat contours</code> and simplify them a little further (removing deformations or if two significant points are so close together, that I can safely remove one of them)?</p>
  
  <p>I am developing in Java (Android), so not every C/C++ method/type is available to me (or a JNI-call would be a waste).</p>