From 8dfba518849aed76d72cc588765c72f71c91f644 Mon Sep 17 00:00:00 2001 From: Dmitry Budnikov Date: Fri, 25 Oct 2019 17:50:09 +0300 Subject: [PATCH] add empty implementation --- modules/gapi/include/opencv2/gapi/own/mat.hpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/modules/gapi/include/opencv2/gapi/own/mat.hpp b/modules/gapi/include/opencv2/gapi/own/mat.hpp index 191eaa1562..964261bdf0 100644 --- a/modules/gapi/include/opencv2/gapi/own/mat.hpp +++ b/modules/gapi/include/opencv2/gapi/own/mat.hpp @@ -284,7 +284,10 @@ namespace cv { namespace gapi { namespace own { The method returns true if Mat::total() is 0 or if Mat::data is NULL. Because of pop_back() and resize() methods `M.total() == 0` does not imply that `M.data == NULL`. */ - bool empty() const; + bool empty() const + { + return data == 0 || total() == 0 || dims.empty(); + } /** @brief Returns the total number of array elements. -- GitLab