title: Connect white points in black image in matlab
body: <p>I have a black background image with a curved shape consisting of white dots, points. The shape is a closed irregular curve. I have coordinates of these white points. I've been looking for a way to "connect" these dots, to close this line to make shape a closed curve. I can't use dilation and erosion because i need those existing location preserved.</p>
  
  <p>Any ideas?</p>
  
  <p>Example image:<br>
  <img src="https://i.imgur.com/MiIe7DC.jpg" alt=""></p>