Commit Graph

4965 Commits

Author SHA1 Message Date
Alexander Alekhin
cb51a155b2 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-05-29 19:00:14 +00:00
Alexander Alekhin
450dc92452 Merge pull request #20172 from alalek:fixup_19334 2021-05-28 14:09:52 +00:00
Alexander Alekhin
3d394943e6 core(ocl): avoid limit of Image kernel args 2021-05-28 00:43:59 +00:00
Alexander Alekhin
830cb5cad7 Merge pull request #20116 from alalek:highgui_backends 2021-05-26 08:32:14 +00:00
damonyu1989
5f637e5a02
Merge pull request #19778 from damonyu1989:master-riscv-0.7.1
* Add the support for riscv64 vector 0.7.1.

* fixed GCC warnings

* cleaned whitespaces

* Remove the worning by the use of internal API of compiler.

* Update the license header.

* removed trailing whitespaces

Co-authored-by: Vadim Pisarevsky <vadim.pisarevsky@me.com>
Co-authored-by: yulj <linjie.ylj@alibaba-inc.com>
Co-authored-by: Vadim Pisarevsky <vadim.pisarevsky@gmail.com>
2021-05-25 20:15:12 +03:00
Alexander Alekhin
70f69cb265 highgui: backends and plugins 2021-05-24 16:12:02 +00:00
HattrickGenerator
115e471515
Merge pull request #19967 from HattrickGenerator:master
* Adding functions rbegin() and rend() functions to matrix class.
This is important to be more standard compliant with C++ and an ever increasing number of people using standard algorithms for better code readability- and maintainability.

The functions are copy pated from their counterparts (even though they should probably call the counterparts but this gave me some troube).
They return iterators using std::reverse_iterators

Follow up of an open feature request:
https://github.com/opencv/opencv/issues/4641

* Fix rbegin() and rend() and provide tests for them

* Removing unnecessary whitespaces

* Adding rbegin and rend to Mat_ class with the right parameters so we don't need to repeat the template argument.
An instantiating cv::Mat_<int> for example can call it's rbegin() function and doesn't need rbegin<int>() with this convience addition.

Follows what is done for forward iterators

* static cast the vector size (return size_t) to an int (that is required for opencv mat constructor)

Co-authored-by: Stefan <stefan.gerl@tum.de>
2021-05-20 19:21:34 +00:00
Alexander Alekhin
7d66f1e391 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-05-18 18:06:26 +00:00
Giles Payne
6265155ce4
Merge pull request #20092 from komakai:disable_swift_build
Fixes for Swift troubles

* Remove NS_SWIFT_NAME override for Point, Rect, and Size due to Darwin namespace conflict

* Fix swift_type overrides in objc generator

* Add backwards compatibility Swift typealiases for Point, Rect, Size

* Add disable-swift build option to iOS/macOS builds

* Add import directive to swift source when building with disable-swift

Co-authored-by: Chris Ballinger <cballinger@rightpoint.com>
2021-05-18 17:10:51 +03:00
Mikhail Nikolskii
a604d44d06
Merge pull request #19755 from mikhail-nikolskiy:ffmpeg-umat
cv::UMat output/input in VideoCapture/VideoWriter (data stays in GPU memory)

* FFMPEG with UMat input/output

* OpenCL_D3D* context

* fix Linux build

* cosmetic changes

* fix build if USE_AV_HW_CODECS=0

* simplify how child context pointer stored in parent context

* QSV interop with OpenCL on Windows

* detect_msdk.cmake via pkg-config

* fix av_buffer_ref() usage

* revert windows-decode-mfx whitelisting; remove debug msg

* address review comments

* rename property to HW_ACCELERATION_USE_OPENCL

* fix issue with "cl_khr_d3d11_sharing" extension not reported by OpenCL GPU+CPU platform

* core(ocl): add OpenCL stubs for configurations without OpenCL

* videoio(ffmpeg): update #if guards

* Put OpenCL related code under HAVE_OPENCL; simplify reuse of media context from OpenCL context

* videoio(test): skip unsupported tests

- plugins don't support OpenCL/UMat yet
- change handling of *_USE_OPENCL flag

* videoio(ffmpeg): OpenCL dependency

* videoio(ffmpeg): MediaSDK/oneVPL dependency

* cleanup, logging

* cmake: fix handling of 3rdparty interface targets

Co-authored-by: Alexander Alekhin <alexander.a.alekhin@gmail.com>
2021-05-14 16:48:50 +00:00
Francesco Petrogalli
7a31a6edee [build][option] Build option to disable filesystem support. 2021-05-11 12:54:54 +00:00
berak
302c2354a3 core: add missing implementation for Mat::ptr(Vec) 2021-05-09 14:15:12 +02:00
Alexander Alekhin
170bf6d7af Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-05-01 09:44:24 +00:00
Alexander Alekhin
f78cebfc98 Merge pull request #20014 from alalek:fix_core_tls_process_termination 2021-04-30 16:06:40 +00:00
Alexander Alekhin
d2a9ca13f1 core(tls): handle process termination / cleanup issues 2021-04-29 23:25:44 +00:00
Zhuo Zhang
bf26050f7e
Fix missing return type for unsafe CV_XADD function 2021-04-26 20:08:45 +08:00
Alexander Alekhin
cfb77091ca Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-04-15 20:50:26 +00:00
Alexander Alekhin
0649a2fbdb Merge pull request #19886 from alalek:issue_19875 2021-04-14 16:14:44 +00:00
Alexander Alekhin
63ba9970bd Merge pull request #19851 from sturkmen72:update_documentation 2021-04-11 21:44:03 +00:00
Alexander Alekhin
222af8e7e4 core: avoid process cleanup deadlock if TlsStorage is not used 2021-04-09 16:08:08 +00:00
Suleyman TURKMEN
ec8b7c933a Update Documentation 2021-04-08 22:29:45 +03:00
Alexander Alekhin
68d15fc62e Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-04-08 11:23:24 +00:00
Alexander Alekhin
3a8154051f Merge pull request #19810 from aarongreig:aaron/core/relaxClArithmTest 2021-04-06 19:56:46 +00:00
Aaron Greig
f3f46096d6 Relax accuracy requirements in the OpenCL sqrt perf arithmetic test.
Also bring perf_imgproc CornerMinEigenVal accuracy requirements in line with
the test_imgproc accuracy requirements on that test and fix indentation on
the latter.

Partially addresses issue #9821
2021-04-06 17:32:48 +01:00
Alexander Alekhin
125b9f6057 Merge tag '4.5.2' 2021-04-02 17:30:52 +00:00
Alexander Alekhin
69357b1e88 release: OpenCV 4.5.2 2021-04-02 11:23:54 +00:00
Alexander Alekhin
2cf1a13755 Merge tag '3.4.14' 2021-04-02 09:31:32 +00:00
Alexander Alekhin
d0e3e638c3 release: OpenCV 3.4.14 2021-04-01 21:37:19 +00:00
Alexander Alekhin
3e1673e8b2 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-04-01 09:54:57 +00:00
Alexander Alekhin
b26f5b9468 core: backward compatibility for vx_store/vx_store_aligned calls 2021-04-01 02:17:47 +00:00
Alexander Alekhin
908957317f Merge pull request #19813 from alalek:issue_19506 2021-03-31 22:57:50 +00:00
Alexander Alekhin
f82303d614 Merge pull request #19811 from alalek:issue_19599 2021-03-31 22:56:48 +00:00
Alexander Alekhin
8069a6b4f8 core(IPP): disable some ippsMagnitude_32f calls 2021-03-31 13:38:57 +00:00
Alexander Alekhin
a2a92999be core(arithm_op): workaround problem with scalars handling 2021-03-31 10:35:52 +00:00
Vitaly Tuzov
aab62aa6dd
Merge pull request #18952 from terfendail:wui_doc
* Updated UI documentation to address WUI

* Added documentation for vx_ calls

* Removed vx_store operation overload

* Doxyfile updated to enable wide UI

* Enable doxygen documentation for vx_ WUI functions

* Wide intrinsics definition rework

* core: fix SIMD C++ emulator build (supports 128-bit only)
2021-03-30 16:18:03 +00:00
Alexander Alekhin
35eaacd1db Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-03-27 15:35:16 +00:00
Alexander Alekhin
6e8022a3af Merge pull request #19773 from jondea:add-aarch64-specialised-v_expand-3.4 2021-03-26 16:54:51 +00:00
Mikhail Nikolskii
bf9f67e93f
Merge pull request #19783 from mikhail-nikolskiy:interop-perf
Performance optimization in DirectX and VAAPI interop

* optimization in OpenCL NV12<>BGR kernels

* reduce kernel work-size
2021-03-25 21:27:31 +00:00
Jonathan Deakin
29a289dfa1 Add v_expand for AArch64, fuse vmovl+vget_high into vmovl_high 2021-03-23 15:06:41 +00:00
Alexander Alekhin
ca8c3dd9b5 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-03-22 12:05:23 +00:00
Alexander Alekhin
a97f6f8058 js: support setLogLevel() / getLogLevel() calls 2021-03-20 18:14:10 +00:00
Alexander Alekhin
a41394c885 core(parallel): fix plugins handling if no filesystem available 2021-03-18 23:05:12 +00:00
Alexander Alekhin
b19f860384 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-03-13 13:02:18 +00:00
Alexander Alekhin
7a8e171691 Merge pull request #19720 from alalek:ocl_test_skip_spir_amd 2021-03-13 12:48:20 +00:00
Alexander Alekhin
7ca9740da5 Merge pull request #19718 from alalek:backport_19683 2021-03-13 12:46:24 +00:00
Alexander Alekhin
87e607a19b core(ocl): skip SPIR test on AMD devices if problem detected 2021-03-13 06:12:52 +00:00
Dale Phurrough
cbe236652b noexcept def construct Mat, UMat, Mat_, MatSize, MatStep
original commit: 1b0f781b7c
2021-03-12 20:26:32 +00:00
Dan Ben Yosef
d4d805cb3e Avoiding copy by passing param by reference
It is best to pass bad_value_ param by reference to avoid copy.
2021-03-12 14:17:11 -05:00
Sayed Adel
f8181fbef8 core:ppc64 fix detecting CPU features when optimization is off 2021-03-12 02:02:31 +00:00
Alexander Alekhin
c5c2b6f9bf Merge pull request #19683 from diablodale:add_defconstruct_noexcept_matumat 2021-03-11 22:02:06 +00:00
Sayed Adel
84fcc4ab9b core:ppc64 fix the build with the newer versions of Eigen on IBM/Power
It also fixes the build when universal intrinsics is disabled
   via `-DDCV_ENABLE_INTRINSICS=OFF`.
2021-03-09 19:20:18 +02:00
Alexander Alekhin
d643a90efa Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-03-06 17:31:08 +00:00
Vitaly Tuzov
04a9ff88d8
Merge pull request #19622 from terfendail:ref_doc
* Updated cpp reference implementations for a few intrinsics to address wide universal intrinsics as well

* Updated cpp reference implementations for a few more universal intrinsics
2021-03-06 17:22:21 +00:00
cyy
b450dd7a87
Merge pull request #19565 from cyyever:minor_fix
Local objects optimization in calibration init

* use emplace_back

* use {} initilization

* remove a tailing white space
2021-03-05 15:04:51 +00:00
Mradul Agrawal
640f188ca2
Merge pull request #19583 from theroyalpekka:patch-1
* Update polynom_solver.cpp

This pull request is in the response to Issue  #19526. I have fixed the problem with the cube root calculation of 2*R. The Issue was in the usage of pow function with negative values of R, but if it is calculated for only positive values of R then changing x0 according to the parity of R, the Issue is resolved. Kindly consider it, Thanks!

* add cv::cubeRoot(double)

Co-authored-by: Alexander Alekhin <alexander.a.alekhin@gmail.com>
2021-03-05 13:55:52 +00:00
Alexander Smorkalov
2e429268ff
Merge pull request #19668 from asmorkalov:as/filesystem_py
* Add Python Bindings for getCacheDirectory function

* Added getCacheDirectory interop test with image codecs.

Co-authored-by: Sergey Slashchinin <sergei.slashchinin@xperience.ai>
2021-03-04 16:17:57 +00:00
Alexander Alekhin
cbfd38bd41 core: rework code locality
- to reduce binaries size of FFmpeg Windows wrapper
- MinGW linker doesn't support -ffunction-sections (used for FFmpeg Windows wrapper)
- move code to improve locality with its used dependencies
- move UMat::dot() to matmul.dispatch.cpp (Mat::dot() is already there)
- move UMat::inv() to lapack.cpp
- move UMat::mul() to arithm.cpp
- move UMat:eye() to matrix_operations.cpp (near setIdentity() implementation)
- move normalize(): convert_scale.cpp => norm.cpp
- move convertAndUnrollScalar(): arithm.cpp => copy.cpp
- move scalarToRawData(): array.cpp => copy.cpp
- move transpose(): matrix_operations.cpp => matrix_transform.cpp
- move flip(), rotate(): copy.cpp => matrix_transform.cpp (rotate90 uses flip and transpose)
- add 'OPENCV_CORE_EXCLUDE_C_API' CMake variable to exclude compilation of C-API functions from the core module
- matrix_wrap.cpp: add compile-time checks for CUDA/OpenGL calls
- the steps above allow to reduce FFmpeg wrapper size for ~1.5Mb (initial size of OpenCV part is about 3Mb)

backport is done to improve merge experience (less conflicts)
backport of commit: 65eb946756
2021-03-02 23:24:28 +00:00
Alexander Alekhin
a823b06fa5 pre: OpenCV 4.5.2 (version++) 2021-03-02 23:20:59 +00:00
Alexander Alekhin
a123c48d4d pre: OpenCV 3.4.14 (version++) 2021-03-02 20:47:29 +00:00
Alexander Alekhin
65eb946756 core: rework code locality
- to reduce binaries size of FFmpeg Windows wrapper
- MinGW linker doesn't support -ffunction-sections (used for FFmpeg Windows wrapper)
- move code to improve locality with its used dependencies
- move UMat::dot() to matmul.dispatch.cpp (Mat::dot() is already there)
- move UMat::inv() to lapack.cpp
- move UMat::mul() to arithm.cpp
- move UMat:eye() to matrix_operations.cpp (near setIdentity() implementation)
- move normalize(): convert_scale.cpp => norm.cpp
- move convertAndUnrollScalar(): arithm.cpp => copy.cpp
- move scalarToRawData(): array.cpp => copy.cpp
- move transpose(): matrix_operations.cpp => matrix_transform.cpp
- move flip(), rotate(): copy.cpp => matrix_transform.cpp (rotate90 uses flip and transpose)
- add 'OPENCV_CORE_EXCLUDE_C_API' CMake variable to exclude compilation of C-API functions from the core module
- matrix_wrap.cpp: add compile-time checks for CUDA/OpenGL calls
- the steps above allow to reduce FFmpeg wrapper size for ~1.5Mb (initial size of OpenCV part is about 3Mb)
2021-03-02 11:27:58 +00:00
Dale Phurrough
1b0f781b7c
noexcept def construct Mat, UMat, Mat_, MatSize, MatStep 2021-03-01 22:42:13 +01:00
Alexander Alekhin
e0265c67c6 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-02-27 17:41:57 +00:00
Federico Martinez
773262bc09 Fix UB in CopyMakeConstBoder_8u
Caused by overflow of arithmetic operators conversion rank
2021-02-26 19:15:50 +00:00
Alexander Alekhin
67b6ef4c2a Merge pull request #19503 from komakai:fix-android-putget 2021-02-24 21:07:13 +00:00
Alexander Alekhin
7ffc4b57aa Merge pull request #19535 from alalek:issue_18897 2021-02-23 22:42:51 +00:00
Alexander Alekhin
9d89edff2f Merge pull request #19594 from alalek:hotfix_19470 2021-02-22 08:29:10 +00:00
Alexander Alekhin
599d64a405 core(parallel): fix JS build, fix OpenMP version dump 2021-02-21 22:55:01 +00:00
Alexander Alekhin
0a6f216f83 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-02-21 20:14:09 +00:00
Alexander Alekhin
1d0334fc07 Merge pull request #19584 from diablodale:fix19573_ocl_move 2021-02-21 19:20:03 +00:00
Alexander Alekhin
309e1e2b1d core(InputArray): replace STD_ARRAY to MATX
- remove duplication kind
2021-02-21 19:12:21 +00:00
Dale Phurrough
96a15434a2
add move construct/assigns to cv::ocl main classes
- enables inline construct and assigns with r-values
- enables compiler-created default move
  construct/assigns
- includes test cases
2021-02-20 18:56:04 +01:00
Dale Phurrough
4badf640bf add noexcept to default constructors of cv::ocl
- follows iso c++ guideline C.44
- enables default compiler-created constructors to
  also be noexcept

original commit: 77e26a7db3

- handled KernelArg, Image2D
2021-02-20 16:20:25 +00:00
Dale Phurrough
77e26a7db3
add noexcept to default constructors of cv::ocl
- follows iso c++ guideline C.44
- enables default compiler-created constructors to
  also be noexcept
2021-02-20 14:16:47 +01:00
Alexander Alekhin
54d80d9168 Merge pull request #19561 from mshabunin:plugin-load-now 2021-02-19 11:53:04 +00:00
Alexander Alekhin
3dd55d284d core(libva): use dynamic loader 2021-02-19 10:32:59 +00:00
Giles Payne
5cf08b0722 Fix/optimize Android put/get functions 2021-02-19 17:10:11 +09:00
Maksim Shabunin
b5a4bd22fb plugins: use RTLD_NOW instead of RTLD_LAZY 2021-02-18 14:45:08 +03:00
Liangqian
0aca3fb5af
Merge pull request #19026 from chargerKong:dualquat
Dual quaternion

* create dual quaternion;
basic operations, functions(exp,log,norm,inv), to/from mat, sclerp.

* add dqb, dqs, gdqb, to/from affine3;
change algorithm of norm, inv, getTranslation, createFromPitch, normalize;
change type translation to Vec3;
comment improve;

* try fix warning: unreferenced local function

* change exp calculation;
add func(obj) operations;

* Change the algorithm of log function;
add assumeUnit in getRotation;
remove dqs;
change std::vector to InputArray

* fix warning: doxygen and Vec<double, 0>

* fix warning: doxygen and Vec<double, 0>

* add inputarray param for gdqb

* change int to size_t

* win cl warning fix

* replace size_t by int at using Mat.at() function

* replace double by float

* interpolation fix

* replace (i, 0) to (i)

* core(quat): exclude ABI, test_dualquaternion=>test_quaternion.cpp

Co-authored-by: arsaratovtsev <arsaratovtsev@intel.com>
Co-authored-by: Alexander Alekhin <alexander.a.alekhin@gmail.com>
2021-02-17 17:05:08 +00:00
Alexander Alekhin
6d3502833f core: include version.hpp in cvdef.h, fix precomp.hpp usage 2021-02-16 11:10:45 +00:00
Alexander Alekhin
cc73c36e32 core(parallel): plugins support 2021-02-15 17:07:36 +00:00
Zhuo Zhang
743099f9f9
Merge pull request #19521 from zchrissirhcz:3.4-fix-core-module-android-arm64-build
* fix core module android arm64 build

* fix core module android build when neon is off

When building for Android ARM platform, cmake with
`-D CV_DISABLE_OPTIMIZATION=ON`, the expected behavior is
not using ARM NEON, using naive computation instead.

This commit fix the un-expected compile error for neon intrinsincs.
2021-02-14 21:37:11 +03:00
Alexander Alekhin
e5d78960c6 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-02-12 21:34:49 +00:00
Francesco Petrogalli
6ee23c9b85
Merge pull request #19486 from fpetrogalli:dotprod_fast-3.4
* [hal][neon] Optimize the v_dotprod_fast intrinsics for aarch64.

On Armv8 in AArch64 execution mode, we can skip the sequence

   v<op>_<ty>(vget_high_<ty>(x), vget_high_<ty>(y))

in favour of

   v<op>_high_<ty>(x, y)

This has better changes for recent compilers to use less data movement
operations and better register allocation. See for example:

   https://godbolt.org/z/bPq7vd

* [hal][neon] Fix build failure on armv7.

* [hal][neon] Address review comments in PR.

PR: https://github.com/opencv/opencv/pull/19486

* [hal][neon] Define macro to check for the AArch64 execution state of Armv8.

* [hal][neon] Fix macro definition for AArch64.

The fix is needed to prevent warnings when building for Armv7.
2021-02-11 13:24:09 +00:00
Vincent Rabaud
847b16fb76 Disable thread sanitization when CV_USE_GLOBAL_WORKERS_COND_VAR is not set.
This fixes #19463
2021-02-09 14:12:39 +01:00
Alexander Alekhin
6b474c4051 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-02-06 00:44:11 +00:00
Alexander Alekhin
e6959055b5 core(cuda.hpp): fix GpuMatND compilation with GCC < 5 2021-02-05 22:42:56 +00:00
Namgoo Lee
7ea21c4b3c
Merge pull request #19259 from nglee:dev_gpumatnd1
Minimal implementation of GpuMatND

* GpuMatND - minimal implementation

* GpuMatND - createGpuMatHeader

* GpuMatND - GpuData, offset, getDevicePtr(), license

* reviews

* reviews
2021-02-05 20:30:37 +00:00
Alexander Alekhin
6ca46afa63 Merge pull request #19286 from diablodale:add-cuda-stream-constructor 2021-02-03 09:55:02 +00:00
Pavel Rojtberg
6c1a433c4c python: also catch general c++ exceptions
they might be thrown from third-party code (notably Ogre in the ovis
module).
While Linux is kind enough to print them, they cause instant termination
on Windows.
Arguably, they do not origin from OpenCV itself, but still this helps
understanding what went wrong when calling an OpenCV function.
2021-02-02 21:16:01 +01:00
Alexander Alekhin
2b787eb4b8 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-01-31 17:44:15 +00:00
Alexander Alekhin
5ab4623c2a Merge pull request #19430 from alalek:fixup_19216 2021-01-31 17:41:24 +00:00
Alexander Alekhin
cdf73f2e05 Merge pull request #19427 from alalek:issue_19426 2021-01-31 14:24:37 +00:00
Alexander Alekhin
30bef20e22 js: fix SIMD build 2021-01-31 00:12:51 +00:00
Alexander Alekhin
c5bf15e009 build: fix cv2.cpp compilation 2021-01-30 11:32:27 +00:00
Maksim Shabunin
694fe3e7d2 core, gapi: supported build with oneTBB 2021 2021-01-29 02:38:05 +03:00
Dale Phurrough
34c3f0f495
add cuda::Stream constructor with cuda flags 2021-01-28 16:14:01 +01:00
Alexander Alekhin
37c12db366 Merge pull request #19365 from alalek:parallel_api 2021-01-27 18:12:15 +00:00
Alexander Alekhin
b73bf03bfc core: parallel backends API
- allow to replace parallel_for() backend
2021-01-27 14:15:33 +00:00
Alexander Alekhin
e85b41f9be Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-01-25 22:42:13 +00:00
Alexander Alekhin
857f339914 Merge pull request #19385 from alalek:ocl_isOpenCLActivated_update 2021-01-25 13:54:00 +00:00