forked from pool/opencv
- Add patch to fix use of headers from C: * build-workaround-issues-with-c.patch - Update to 3.4.1: * Added support for quantized TensorFlow networks * OpenCV is now able to use Intel DL inference engine as DNN acceleration backend * Added AVX-512 acceleration to the performance-critical kernels * For more information, read https://github.com/opencv/opencv/wiki/ChangeLog#version341 - Update contrib modules to 3.4.1: * No changelog available - Change mechanism the contrib modules are built - Include LICENSE of contrib tarball as well - Build with python3 on >= 15 - Add patch to fix build on i386 without SSE: * fix-build-i386-nosse.patch - Refresh patches: * fix_processor_detection_for_32bit_on_64bit.patch * opencv-build-compare.patch - Mention all libs explicitly - Rebase 3.4.0 update from i@marguerite.su - update to 3.4.0 * Added faster R-CNN support * Javascript bindings have been extended to cover DNN module * DNN has been further accelerated for iGPU using OpenCL * On-disk caching of precompiled OpenCL kernels has been finally implemented OBS-URL: https://build.opensuse.org/request/show/612803 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/opencv?expand=0&rev=71
57 lines
2.0 KiB
Diff
57 lines
2.0 KiB
Diff
From 549b5df22520b60b91dd77096434d79425b31ac2 Mon Sep 17 00:00:00 2001
|
|
From: Alexander Alekhin <alexander.alekhin@intel.com>
|
|
Date: Mon, 28 May 2018 18:07:23 +0300
|
|
Subject: [PATCH] build: workaround issues with C compilation mode
|
|
|
|
- cvdef.h + cvRound (double only)
|
|
- highgui_c.h
|
|
---
|
|
modules/core/include/opencv2/core/cvdef.h | 8 +++++++-
|
|
modules/highgui/include/opencv2/highgui/highgui_c.h | 2 ++
|
|
2 files changed, 9 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/modules/core/include/opencv2/core/cvdef.h b/modules/core/include/opencv2/core/cvdef.h
|
|
index a87ced09d78..4ab72b34cc1 100644
|
|
--- a/modules/core/include/opencv2/core/cvdef.h
|
|
+++ b/modules/core/include/opencv2/core/cvdef.h
|
|
@@ -480,7 +480,7 @@ Cv64suf;
|
|
// Integer types portatibility
|
|
#ifdef OPENCV_STDINT_HEADER
|
|
#include OPENCV_STDINT_HEADER
|
|
-#else
|
|
+#elif defined(__cplusplus)
|
|
#if defined(_MSC_VER) && _MSC_VER < 1600 /* MSVS 2010 */
|
|
namespace cv {
|
|
typedef signed char int8_t;
|
|
@@ -517,9 +517,15 @@ typedef ::int64_t int64_t;
|
|
typedef ::uint64_t uint64_t;
|
|
}
|
|
#endif
|
|
+#else // pure C
|
|
+#include <stdint.h>
|
|
#endif
|
|
|
|
|
|
//! @}
|
|
|
|
+#ifndef __cplusplus
|
|
+#include "opencv2/core/fast_math.hpp" // define cvRound(double)
|
|
+#endif
|
|
+
|
|
#endif // OPENCV_CORE_CVDEF_H
|
|
diff --git a/modules/highgui/include/opencv2/highgui/highgui_c.h b/modules/highgui/include/opencv2/highgui/highgui_c.h
|
|
index 1eb414a76ca..35413139c79 100644
|
|
--- a/modules/highgui/include/opencv2/highgui/highgui_c.h
|
|
+++ b/modules/highgui/include/opencv2/highgui/highgui_c.h
|
|
@@ -135,8 +135,10 @@ CVAPI(int) cvNamedWindow( const char* name, int flags CV_DEFAULT(CV_WINDOW_AUTOS
|
|
CVAPI(void) cvSetWindowProperty(const char* name, int prop_id, double prop_value);
|
|
CVAPI(double) cvGetWindowProperty(const char* name, int prop_id);
|
|
|
|
+#ifdef __cplusplus // FIXIT remove in OpenCV 4.0
|
|
/* Get window image rectangle coordinates, width and height */
|
|
CVAPI(cv::Rect)cvGetWindowImageRect(const char* name);
|
|
+#endif
|
|
|
|
/* display image within window (highgui windows remember their content) */
|
|
CVAPI(void) cvShowImage( const char* name, const CvArr* image );
|