Fix for spurious assert in cv::compareHist

When comparing histograms that look like multi-channel images (e.g a 3D histogram, of 4x4x4 bins, might appear as a CV_32FC4 matrix), cv::compareHist would complain because it was expecting the matrix type() == CV_32F. Now we test matrix depth() == CV_32F instead.
Take account of multi-channel matrices when comparing histograms

Ensure that all channels are considered when comparing multi-channel histograms
fixed NPP error constants usage
fixed constructors for functional objects (added __host__ modifier)
rewrite core/cuda/vec_math.hpp file

old version isn't compiled with CUDA 5.5
new version doesn't depend on functional.hpp
fixed BroxOpticalFlow regression test

the output of BroxOpticalFlow differs a bit in CUDA 5.5
fixed BoxFilter sanity test (different rounding results)
fixed BroxOpticalFlow sanity test (increase epsilon value)
Merge pull request #964 from jet47:cuda-5.5-support
fixing Java wrapper for mixChannels
'dst' should be treated as an input arg (epilog not needed)
Merge pull request #856 from ericgreveson:master
Merge pull request #958 from apavlenko:fix_java_mixchannels