title: DETECT the Edge of a Document in iPhoneSDK
body: <p>I am looking something like attached image, How can I implement this in iPhoneSDK.</p>
  
  <p>Can anybody suggest me <strong>some open source API</strong> or <strong>Algorithm Code</strong> to detect the corners of captured image of a document.</p>
  
  <p>Some How, I got an open source API called <strong>OpenCV</strong> which recognize the <a href="http://niw.at/articles/2009/03/14/using-opencv-on-iphone/en" rel="noreferrer">Human Face</a> very well. I want to use the same API if possible.Now the problem Is how can I make the changes in those static libraries according to my requirement to Scan the Document edges.
  <em>Alternatively</em>,</p>
  
  <p><strong>how to detect for the square/rectangle object in the captured image ?</strong></p>
  
  <p><img src="https://i.stack.imgur.com/9UmZM.png" alt="enter image description here"></p>