Refactored the code a little bit.

Added the contours getter. Still not working (gets one single contour
as the whole image.) Needs some more work.