Ask Your Question
1

Superresolution: error with createOptFlow_DualTVL1()

asked 2013-05-21 13:16:46 -0600

student gravatar image

Hi

For choosing optical flow with super-resolution, the following compiles fine:

Ptr<DenseOpticalFlowExt> opflow = createOptFlow_Farneback();

But the following gives error:

Ptr<DenseOpticalFlowExt> opflow = createOptFlow_DualTVL1();

The error given is:

error C2668: 'cv::superres::createOptFlow_DualTVL1' : ambiguous call to overloaded function

How can I avoid the error? Thanks.

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
2

answered 2013-05-22 01:59:29 -0600

Vladislav Vinogradov gravatar image

Add superres:: prefix:

Ptr<DenseOpticalFlowExt> opflow = superres::createOptFlow_DualTVL1();
edit flag offensive delete link more

Comments

Thanks, it works! But I'm confused on why createOptFlow_DualTVL1() needs superres:: prefix in front whilst createOptFlow_Farneback() doesn't need it. Also I have the "using namespace superres;" above the main function.

student gravatar imagestudent ( 2013-05-22 05:59:46 -0600 )edit

There are two function createOptFlow_DualTVL1:

cv::Ptr<cv::DenseOpticalFlow> cv::createOptFlow_DualTVL1();

cv::Ptr<cv::superres::DenseOpticalFlowExt> cv::superres::createOptFlow_DualTVL1();

If you use "using namespace ..." compiler can't decide which function used.

Vladislav Vinogradov gravatar imageVladislav Vinogradov ( 2013-05-22 06:45:15 -0600 )edit

Question Tools

Stats

Asked: 2013-05-21 13:16:46 -0600

Seen: 1,458 times

Last updated: May 22 '13