Commit Graph

59 Commits

Author SHA1 Message Date
Kumataro
dba7186378
Merge pull request #24271 from Kumataro:fix24163
Fix to convert float32 to int32/uint32 with rounding to nearest (ties to even). #24271

Fix https://github.com/opencv/opencv/issues/24163

### Pull Request Readiness Checklist

See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request

- [x] I agree to contribute to the project under Apache 2 License.
- [x] To the best of my knowledge, the proposed patch is not based on a code under GPL or another license that is incompatible with OpenCV
- [x] The PR is proposed to the proper branch
- [x] There is a reference to the original bug report and related work
- [x] There is accuracy test, performance test and test data in opencv_extra repository, if applicable
      Patch to opencv_extra has the same branch name.
- [x] The feature is well documented and sample code can be built with the project CMake

(carotene is BSD)
2023-12-25 12:17:17 +03:00
Tomoaki Teshima
2146bbb7bd fix warning in Clang 10 2023-12-07 21:35:44 +09:00
Alexander Alekhin
420db56ffd Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2022-12-18 02:17:17 +00:00
Alexander Smorkalov
423bc515e5 Integer underflow fix for morphologyEx in Carotene (arm). 2022-12-09 18:08:22 +03:00
Alexander Alekhin
762481411d Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2022-10-15 16:44:47 +00:00
Alexander Smorkalov
41ef2bfb16
Merge pull request #21945 from driftee:fix-3rdparty_carotene_blur
fix a 3rd party blur3x3 function(the 7th value in tcurr should be set to the 5th value in old tcurr, which will be be overwritten by the 3rd value in old tcurr)
2022-09-16 16:23:09 +03:00
Andrey Senyaev
e1305e8d05 Fixed a warning in case of typename on macOS ARM64 2022-08-25 18:17:03 +03:00
Andrey Senyaev
ef570e4e13 Suppress warnings in carotene on macOS ARM64 for 3.4 branch 2022-08-22 17:42:22 +03:00
Alexander Alekhin
2ebdc04787 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2022-08-14 15:50:42 +00:00
Tomoaki Teshima
87ef6a9cc1 build: suppress the warning
DRY
bump the version
2022-07-12 19:42:39 +09:00
lgx
2b8094f915 fix a blur3x3 function 2022-05-02 20:42:41 +08:00
Alexander Alekhin
d24befa0bc Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-12-11 15:18:57 +00:00
Alexander Alekhin
a3287b85c5 carotene: disable YUV color conversions (bit-exact issue) 2021-12-04 07:32:57 +00:00
Alexander Alekhin
24fcb7f813 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-09-25 17:50:00 +00:00
Amir Tulegenov
86a51015b1
Merge pull request #19554 from amirtu:OCV-215_cvtColorTwoPlane_wrong_output_when_Y_Plane_Mat_has_step
different paddings in cvtColorTwoPlane() for biplane YUV420

* Different paddings support in cvtColorTwoPlane() for biplane YUV420

* Build fix for dispatch case.

* Resoted old behaviour for y.step==uv.step to exclude perf regressions.

Co-authored-by: amir.tulegenov <amir.tulegenov@xperience.ai>
Co-authored-by: Alexander Smorkalov <alexander.smorkalov@xperience.ai>
2021-09-22 17:42:32 +03:00
Alexander Alekhin
0a6f216f83 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-02-21 20:14:09 +00:00
Dan Ben-Yosef
f0445295bd
Merge pull request #19525 from danbey:Fix-cppcheck-error-in-carotete-lib
* Reduce if statement as it has the same expression on both sides of '&&'

If statement has the same expression on both sides so this can be reduce

Signed-off-by: Dan Ben Yosef <danbey@gmail.com>

* The if statement is to check width and height
2021-02-15 19:58:37 +00:00
Alexander Alekhin
d9a62c42e5 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2020-10-28 14:41:08 +00:00
Alexander Alekhin
364702b1c9 cmake(3rdparty): use EXCLUDE_FROM_ALL 2020-10-28 11:56:12 +00:00
Alexander Alekhin
fa25faa2d2 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2020-08-06 14:15:52 +00:00
Maksim Shabunin
866468cc3e Fix Carotene compilation with XCode 2020-07-30 22:52:29 +03:00
Alexander Alekhin
560f85f8e5 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2020-01-28 14:26:57 +03:00
Alexander Alekhin
ffaf15d0d9 cmake: reuse OpenCV NEON detection in carotene
- use carotene if NEON available only
2020-01-24 16:42:56 +03:00
Alexander Alekhin
3d14dd4e39 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2020-01-22 16:58:30 +03:00
Alexander Alekhin
f429cee5d1 Merge pull request #16369 from kraj:gcc10 2020-01-17 08:58:20 +00:00
Khem Raj
2bd9488475 carotene: Replace ipcp-unit-growth with ipa-cp-unit-growth on gcc >= 10
gcc 10+ has renamed this option, therefore check for gcc version before
deciding which name to use for opt parameter

Signed-off-by: Khem Raj <raj.khem@gmail.com>
2020-01-16 11:02:25 -08:00
Alexander Alekhin
174b4ce29d Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2019-08-05 18:11:43 +00:00
Tomoaki Teshima
d6ba235655 fix fall through warning 2019-08-05 17:42:48 +09:00
Alexander Alekhin
7e2ebecd52 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2019-01-10 12:29:41 +03:00
Thomas Peters
e8ac3ea9ea fix implicit fallthrough warning. 2019-01-08 09:49:45 -05:00
Alexander Alekhin
cbf80117af eliminate build warnings 2018-12-19 15:42:38 +03:00
Maksim Shabunin
26cb154f40 Fixed NEON detection in Carotene build 2018-11-26 11:33:18 +03:00
Maksim Shabunin
fb6929ac3d Fixed NEON detection in Carotene build 2018-11-26 11:30:20 +03:00
Tomoaki Teshima
3bbc4e44c3 fix test failure of ColorCvtRGB2Gray
- update parameter in carotene
2018-11-16 23:31:01 +09:00
Alexander Alekhin
fd832bb57d core: follow IEEE 754 rules for floating-point division 2018-10-14 10:47:50 +00:00
Tomoaki Teshima
e324d2e534 suppress warning on Arm platform 2018-06-22 20:17:22 +09:00
Tomoaki Teshima
98d9369a38 add new comparison to tolerate with rounding error
* restore resize of carotene
  * clean up the source code
  * remove unused member function (Near)
  * add strict test on the border
2018-04-19 17:31:42 +09:00
Alexander Alekhin
08941b7890 cmake: avoid amending of CMAKE_COMPILER_IS_[GNUCXX|CLANGCXX|CCACHE] vars
- Recommended compiler checks:
  - GCC: CV_GCC
  - Clang: CV_CLANG
- fixed problem with CMAKE_CXX_COMPILER_ID=Clang/AppleClang mess on MacOSX
  Details: cmake --help-policy CMP0025
- do not declare Clang as GCC compiler
2018-03-27 16:16:59 +03:00
Tomoaki Teshima
06babf90a5 let the test OCL_ImgprocWarp/Resize.Mat pass on ARM/Aarch64
* disable carotenete when calling resize on ARM/Aarch64
  * loosen eps on Aarch64
2018-03-22 21:35:34 +09:00
Alexander Alekhin
50365b7741 cmake: update CMAKE_POSITION_INDEPENDENT_CODE 2017-12-15 15:56:19 +03:00
Vitaly Tuzov
51cb56ef2c Implementation of bit-exact resize. Internal calls to linear resize updated to use bit-exact version. (#9468) 2017-12-13 15:00:38 +03:00
Khem Raj
2c7a123ed8 Do not enable asm with clang
clang pretends to be gcc 4.2.0 which means we will
use inline asm for no reason, instead of builtins
on clang when possible.

Signed-off-by: Khem Raj <raj.khem@gmail.com>
2017-09-19 18:09:30 -07:00
Maksim Shabunin
248e2c7d47 Fixed some issues found by static analysis 2017-09-08 12:22:12 +03:00
Alexander Alekhin
97aaaf50b8 carotene: removed unnecessary 'register' specifier 2017-08-23 18:57:00 +03:00
Alexander Alekhin
c5f2170ce8 carotene: don't use __asm__ with aarch64 2017-08-23 18:56:53 +03:00
Alexander Alekhin
a4a47b538c build: detect Android via '__ANDROID__' macro
https://sourceforge.net/p/predef/wiki/OperatingSystems
2017-07-10 12:43:59 +03:00
Tony Lian
c8783f3e23 Merge pull request #9075 from TonyLianLong:master
Remove unnecessary Non-ASCII characters from source code (#9075)

* Remove unnecessary Non-ASCII characters from source code

Remove unnecessary Non-ASCII characters and replace them with ASCII
characters

* Remove dashes in the @param statement

Remove dashes and place single space in the @param statement to keep
coding style

* misc: more fixes for non-ASCII symbols

* misc: fix non-ASCII symbol in CMake file
2017-07-03 16:14:17 +00:00
Alexander Alekhin
3e3e2dd512 android: make optional "cpufeatures", build fixes for NDK r15 2017-06-21 13:34:19 +03:00
Tomoaki Teshima
2a91453ef1 brush up divSaturate of carotene
* use rounding to nearest same as divSaturateQ
2016-10-23 08:51:25 +09:00
Tomoaki Teshima
971a7c88dc let the performance test pass on ARM
* use round-to-neaerest in div of carotene
2016-10-20 10:44:34 +09:00