gapi: fix build, update IE handling, add OPENCV_GAPI_INF_ENGINE

This commit is contained in:
Alexander Alekhin
2020-04-22 21:41:36 +00:00
parent 94e36d8c8d
commit 351fb8c058
3 changed files with 25 additions and 7 deletions
@@ -25,23 +25,27 @@ namespace cv
return result;
}
cv::gapi::own::Mat to_own(Mat&&) = delete;
cv::gapi::own::Mat to_own(Mat&&) = delete;
inline cv::gapi::own::Mat to_own(Mat const& m) {
return (m.dims == 2)
? cv::gapi::own::Mat{m.rows, m.cols, m.type(), m.data, m.step}
: cv::gapi::own::Mat{to_own<int>(m.size), m.type(), m.data};
};
namespace gapi
{
namespace own
{
inline cv::Mat to_ocv(Mat const& m) {
return m.dims.empty()
? cv::Mat{m.rows, m.cols, m.type(), m.data, m.step}
: cv::Mat{m.dims, m.type(), m.data};
}
cv::Mat to_ocv(Mat&&) = delete;
cv::Mat to_ocv(Mat&&) = delete;
} // namespace own
} // namespace gapi
} // namespace cv