Pavlidis algorithm

Add Pavlidis contour tracing algorithm.