Trying to add depth refinement. Not finished. May have bugs inside.

Signed-off-by: ezheng <ezheng@cs.unc.edu>
fix a very important bug. Happens when handling the pixels around the boundary. This bug should also exists in some other versions

Signed-off-by: Enliang <ezheng@cs.unc.edu>
depthmap refinement. This is the correct version. A bunch of bugs were fixed

Signed-off-by: Enliang <ezheng@cs.unc.edu>
fix a bug when drawing samples. The random float value can be slightly (epison) bigger than 1.0f. I added 1.0f - FLT_SPSILON

Signed-off-by: Enliang <ezheng@cs.unc.edu>
applied a threshold on the NCC value to remove noise. (Not widely tested yet)

Signed-off-by: Enliang <ezheng@cs.unc.edu>
Merge branch 'master' of github.com:ezheng/patchMatch_cuda
change the window size dynamically. It is still  hard-coded in line 462--533

Signed-off-by: Enliang <ezheng@cs.unc.edu>