diff --git a/modules/core/include/opencv2/core/bindings_utils.hpp b/modules/core/include/opencv2/core/bindings_utils.hpp index 9c8f9e0f2b..dd00b59ffd 100644 --- a/modules/core/include/opencv2/core/bindings_utils.hpp +++ b/modules/core/include/opencv2/core/bindings_utils.hpp @@ -335,23 +335,6 @@ namespace fs { //! @} // core_utils } // namespace cv::utils -//! @cond IGNORED - -CV_WRAP static inline -int setLogLevel(int level) -{ - // NB: Binding generators doesn't work with enums properly yet, so we define separate overload here - return cv::utils::logging::setLogLevel((cv::utils::logging::LogLevel)level); -} - -CV_WRAP static inline -int getLogLevel() -{ - return cv::utils::logging::getLogLevel(); -} - -//! @endcond IGNORED - } // namespaces cv / utils #endif // OPENCV_CORE_BINDINGS_UTILS_HPP diff --git a/modules/core/include/opencv2/core/utils/logger.hpp b/modules/core/include/opencv2/core/utils/logger.hpp index e5bf455125..c58b0ccf6a 100644 --- a/modules/core/include/opencv2/core/utils/logger.hpp +++ b/modules/core/include/opencv2/core/utils/logger.hpp @@ -22,9 +22,9 @@ namespace logging { /** Set global logging level @return previous logging level */ -CV_EXPORTS LogLevel setLogLevel(LogLevel logLevel); +CV_EXPORTS_W LogLevel setLogLevel(LogLevel logLevel); /** Get global logging level */ -CV_EXPORTS LogLevel getLogLevel(); +CV_EXPORTS_W LogLevel getLogLevel(); CV_EXPORTS void registerLogTag(cv::utils::logging::LogTag* plogtag); diff --git a/modules/python/bindings/CMakeLists.txt b/modules/python/bindings/CMakeLists.txt index c511b9bc80..d8753b1e2d 100644 --- a/modules/python/bindings/CMakeLists.txt +++ b/modules/python/bindings/CMakeLists.txt @@ -51,7 +51,7 @@ ocv_list_filterout(opencv_hdrs "modules/core/include/opencv2/core/fast_math.hpp" ocv_list_filterout(opencv_hdrs "modules/core/.*/cuda/") ocv_list_filterout(opencv_hdrs "modules/core/.*/hal/") ocv_list_filterout(opencv_hdrs "modules/core/.*/opencl/") -ocv_list_filterout(opencv_hdrs "modules/.+/utils/.*") +ocv_list_filterout(opencv_hdrs "modules/.+/utils/trace.hpp") ocv_list_filterout(opencv_hdrs "modules/.*\\\\.inl\\\\.h*") ocv_list_filterout(opencv_hdrs "modules/.*_inl\\\\.h*") ocv_list_filterout(opencv_hdrs "modules/.*\\\\.details\\\\.h*")