Added contour extensions and demo