Skip to content

ocl_minMaxIdx to call minmaxloc.cl for OpenCL 1.2+ only#22865

Merged
alalek merged 3 commits intoopencv:3.4from
cpoerschke:3.4-issue-22860
Dec 3, 2022
Merged

ocl_minMaxIdx to call minmaxloc.cl for OpenCL 1.2+ only#22865
alalek merged 3 commits intoopencv:3.4from
cpoerschke:3.4-issue-22860

Conversation

@cpoerschke
Copy link
Copy Markdown
Contributor

naive change for the #22860 issue (but untested since I don't have OpenCL 1.1 here)

Pull Request Readiness Checklist

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

  • I agree to contribute to the project under Apache 2 License.
  • 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
  • The PR is proposed to the proper branch
  • There is a reference to the original bug report and related work
  • There is accuracy test, performance test and test data in opencv_extra repository, if applicable
    Patch to opencv_extra has the same branch name.
  • The feature is well documented and sample code can be built with the project CMake

CV_Assert( (cn == 1 && (_mask.empty() || _mask.type() == CV_8U)) ||
(cn > 1 && _mask.empty() && !minIdx && !maxIdx) );

#if defined(CL_VERSION_1_2)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This doesn't work in this way.
You have disabled OpenCL call everywhere.

@cpoerschke cpoerschke changed the title cv::minMaxIdx to call minmaxloc.cl for OpenCL 1.2+ only ocl_minMaxIdx to call minmaxloc.cl for OpenCL 1.2+ only Nov 27, 2022
@cpoerschke cpoerschke requested a review from alalek December 1, 2022 00:16
@alalek alalek merged commit 4792837 into opencv:3.4 Dec 3, 2022
@alalek alalek mentioned this pull request Dec 3, 2022
@alalek alalek mentioned this pull request Jan 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

minMaxLoc incompatible with some OpenCL implementations

3 participants