Shape discovery: reshape if above

* Reshapes rect if something is above
  and gesture is PALM (uses last gesture).
* Fixes for HAAR calibration after new
  resolution support.
Histograms: cleaning

* Much cleaner version of histogram tools.
* New functions for: init and release camera
* Main refactored with new functions.