Skip to content

Commit 61cbb44

Browse files
czgdp1807alalek
authored andcommitted
Merge pull request #2336 from czgdp1807:issue-2333
* corrected scope of CV_Error() * removed the return statement
1 parent 3146e4a commit 61cbb44

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

modules/cudaoptflow/src/nvidiaOpticalFlow.cpp

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,10 @@ Ptr<NvidiaOpticalFlow_1_0> cv::cuda::NvidiaOpticalFlow_1_0::create(int, int, int
1212

1313
#elif !defined HAVE_NVIDIA_OPTFLOW
1414

15-
CV_Error(cv::Error::HeaderIsNull, "Nvidia Optical Flow headers not found. Make sure cmake downloads it properly");
15+
Ptr<NvidiaOpticalFlow_1_0> cv::cuda::NvidiaOpticalFlow_1_0::create(int, int, int, NVIDIA_OF_PERF_LEVEL, bool, bool)
16+
{
17+
CV_Error(cv::Error::HeaderIsNull, "OpenCV was build without NVIDIA OpticalFlow support");
18+
}
1619

1720
#else
1821

@@ -653,4 +656,4 @@ Ptr<cv::cuda::NvidiaOpticalFlow_1_0> cv::cuda::NvidiaOpticalFlow_1_0::create(
653656
bEnableCostBuffer,
654657
gpuId);
655658
}
656-
#endif
659+
#endif

0 commit comments

Comments
 (0)