Itseez/opencv — pull request #3485 by talaj (2014-12-05 11:28:59+00:00)
Title: fix crash when sample point out of image boundaries

Sample point goes out of image boundaries under certain circumstances. This causes crash as point is used for pointer arithmetic [here](https://github.com/mapycz/opencv/blob/4c426fe26ecbefc4568136083644d50ca1a30ac7/modules/photo/src/calibrate.cpp#L107).