Changed detection thread start and threshold mode

Moved the detection thread to start in the ‘start’ method (and added a
lock) because of issues with it being started multiple times when
switching back to the app.

Added the marker outlines to the threshold mode (this requires making a
clone of the threshold image).

Raised the contour limit to 15000 (from 4000) so less frames are
skipped.
Raised the contour size limit to 50 (from 10) so more contours are
skipped per frame.
These values should probably be settings rather that hard coded.