fix compile problems with contributed ximgproc/xphoto
Merge pull request #3111 from vpisarev:make_ximgproc_compile