ConvexityDefect (Patch #796)


Added by Frankie Fong about 14 years ago. Updated almost 13 years ago.


Status:Done Start date:
Priority:Normal Due date:
Assignee:Vadim Pisarevsky % Done:

0%

Category:imgproc, video
Target version:2.4.0
Affected version: Operating System:
Difficulty: HW Platform:
Pull request:

Description

I am submitting patch that adds a C++ wrapper function for CvConvexityDefects().


convexitydefects.diff (1.8 kB) Frankie Fong, 2011-01-06 10:56 am


Related issues

precedes Patch #1701: findConvexityDefects contribution Done 2012-03-19

Associated revisions

Revision e36ad508
Added by Vadim Pisarevsky almost 13 years ago

added cv::convexityDefects (ticket #796)

Revision aea24ffc
Added by Andrey Pavlenko almost 13 years ago

#796, #1701 fixing doc vs code arg-s naming consistency

Revision ca56e99a
Added by Andrey Kamaev almost 12 years ago

Merge pull request #796 from SpecLad:more-backports

History

Updated by Alexander Shishkov about 13 years ago

  • Description changed from I am submitting patch that adds a C++ wrapper function for [[CvConvexityDefec... to I am submitting patch that adds a C++ wrapper function for CvConvexityDefects(). More

Updated by Kirill Kornyakov about 13 years ago

  • Tracker changed from Feature to Patch

Updated by Tomas Kazmar almost 14 years ago

I would very much like to have access to cvConvexityDefects() functionality using the C++ interface and the new Python bindings...

I tested this patch and unfortunately it does not compile with new Python bindings. Also it uses the C-type cvConvexityDefect, instead of defining the C++ counterpart.

Updated by Frankie Fong almost 13 years ago

I see. okay. So I suppose it's an invalid patch then. I won't be working on this at the moment. But thanks for the feedback.

Updated by Alexander Shishkov almost 13 years ago

  • Priority changed from High to Normal
  • Target version deleted ()

Updated by Alexander Shishkov almost 13 years ago

  • Assignee deleted (Vadim Pisarevsky)

Updated by Vadim Pisarevsky almost 13 years ago

the provided C++ version is not very good, since it outputs sequence containing CvPoint* - very unsafe to use with STL vectors that could be copied or reallocated. Instead, the C++ version returns indices. CvConvexityDefect::depth is represented as a fixed-point number with 8 fractional bits. In other words, the whole CvConvexityDefect structure:

(start, end, depth_point, depth)

is represented as cv::Vec4i:

idx(start), idx(end), idx(depth_point), cvRound(depth*256).
  • Status changed from Open to Done
  • Assignee set to Vadim Pisarevsky

Updated by Vadim Pisarevsky almost 13 years ago

forgot to say that C++ version is put to SVN trunk, r7744.

Updated by Alexander Shishkov almost 13 years ago

  • Target version set to 2.4.0

Also available in: Atom PDF