s(:,1), pts(:,2));
poly = pts(hull, :);
</pre><h2>Compute medial axis<a name="2"></a></h2><pre class="codeinput"><span class="comment">% the result is given as graph : n are nodes (points), and e are edges,</span>
<span class="comment">% contaiing indices of two vertices of an edge.</span>
[n e] = medialAxisConvex(poly);
</pre><h2>Draw result<a name="3"></a></h2><pre class="codeinput"><span class="comment">% format new  figure</span>
figure(4);
axis([0 100 0 100]);
hold <span class="string">on</span