Fixed core for CCORR and SQDIFF. Used float instead of int for CV_8U. Fixed conditions for call dft.