Added function decomposeHomographyMat. New files added are homography_decomp.cpp and test_homography_decomp.cpp.
Modified files calib3d.hpp and camera_calibration_and_3d_reconstruction.rst.
Fixed warnings and parameter name mismatches, added #include needed in some platforms.
Implimentation "cv::Mat::forEach"

I propose forEach method for cv::Mat and cv::Mat_.
This is solution for the overhead of MatIterator_<_Tp>.

I runs a test that micro opecode runs all over the pixel of cv::Mat_<cv::Point3_<uint8_t>>.
And this implementation 40% faster than the simple pointer, 80% faster than iterator.
With OpenMP, 70% faster than simple pointer, 95% faster than iterator (Core i7 920).

Above all, code is more readable.

My test code is here.
    https://gist.github.com/kazuki-ma/8285876

Thanks.
ocl: added runtime flags for debugging
Build both Python 2 and Python 3 bindings

If both Python 2 and Python 3 are found, then build bindings for both of
them during the build process.  Currently, one version of Python is
detected automatically, and building for the other requires changes the
CMake config.

The largest chunk of this change generalizes OpenCVDetectPython.cmake to
find both a Python 2 and Python 3 version of Python.  Secondly, the
opencv_python module is split into two modules, opencv_python2 and
opencv_python3.  Both are built from the same source. but for different
versions of Python.
Used float instead of int for CV_8U in sumTemplate
new block size for dft
added dft for all platforms
initial commit; ml has been refactored; it compiles and the tests run well; some other modules, apps and samples do not compile; to be fixed
Optimize OpenCL version of morfology and box filters for small filter kernels
Removed opencv_legacy dependency from cudaoptflow
Fix some problems
use std::min,max
fixed python bindings generation
fixed compilation of some samples; fixed ANN_MLP::predict
updated documentation for decomposeHomography
added comment.
Merge remote-tracking branch 'upstream/master' into HomographyDecomp
Merge branch 'master' into python2and3
Removed cvCalcOpticalFlowBM from performance test