Unconstrained Polygonal Fitting of 2D Shapes