Merge 2.4 into master

Original pull requests:

* #1722 from StevenPuttemans:feature_1631_second
* #1766 from ilya-lavrenov:ocl_remap_linear
* #1773 from ilya-lavrenov:ocl_buildWarpPerspectiveMaps
* #1775 from ilya-lavrenov:ocl_cvtColor
* #1779 from perping:integral_2.4
* #1780 from ilya-lavrenov:ocl_m_pi
* #1782 from ilya-lavrenov:ocl_adapBilat
* #1783 from SpecLad:cap-no-pattern
* #1784 from SpecLad:ffmpeg-no-png
* #1785 from ilya-lavrenov:ocl_kern_warn
* #1786 from SpecLad:cap-images-file-pattern
* #1788 from alalek:perf_test_skip
* #1789 from ilya-lavrenov:ocl_minMaxLoc
* #1790 from ilya-lavrenov:ocl_ref
* #1792 from ilya-lavrenov:ocl_warp_eps
* #1794 from vrabaud:2.4
* #1796 from ilya-lavrenov:ocl_cvtColor
* #1799 from SpecLad:avformat-53-6
* #1802 from SpecLad:cmake-templates
* #1803 from ilya-lavrenov:ocl_cvtColor
* #1807 from KonstantinMatskevich:intel_bug
* #1808 from alalek:ocl_fix_cvtcolor_xyz
* #1809 from ilya-lavrenov:ocl_resize_nn