title: Python OpenCV find all triangles in image
body: <p>I trying to find all triangle in image with that code without success</p>
  
  <pre><code>import numpy as np
  import cv2
  
  img = cv2.imread('2.jpg')
  
  for gray in cv2.split(img):
      canny = cv2.Canny(gray,50,200)
  
      contours,hier = cv2.findContours(canny,1,2)
      for cnt in contours:
          approx = cv2.approxPolyDP(cnt,0.02*cv2.arcLength(cnt,True),True)
          if len(approx)==3:
              cv2.drawContours(img,[cnt],0,(0,255,0),2)
              tri = approx
  
  for vertex in tri:
      cv2.circle(img,(vertex[0][0],vertex[0][1]),5,255,-1)
  
  cv2.imshow('img',img)
  cv2.waitKey(0)
  cv2.destroyAllWindows()
  </code></pre>
  
  <p>So from this picture</p>
  
  <p><img src="https://i.stack.imgur.com/j2Az8.jpg" alt="So from this"></p>
  
  <p>I want get this ( Look at licence plate, I filled with red lines triangles)</p>
  
  <p><img src="https://i.stack.imgur.com/HyM6m.jpg" alt="enter image description here"></p>
  
  <p>That what I get now</p>
  
  <p><img src="https://i.stack.imgur.com/vvjDV.png" alt="enter image description here"></p>