Working polygonize function (#20).

TODO: tests, better examples, removal of unneeded code copied
from Fiona.