v4r-tuwien / v4r_ros

4 stars 5 forks source link

v4r_ellipses_node randomly crashes #4

Closed JimmyDaSilva closed 8 years ago

JimmyDaSilva commented 8 years ago

Hi all,

I found this package to be quiet useful for detecting holes for peg-in-hole applications. The problem is just that the code sometimes crashes with the following error:

OpenCV Error: Assertion failed (box.size.width >= 0 && box.size.height >= 0 && thickness <= 255) in ellipse, file /build/buildd/opencv-2.4.8+dfsg1/modules/core/src/drawing.cpp, line 1680
terminate called after throwing an instance of 'cv::Exception'
  what():  /build/buildd/opencv-2.4.8+dfsg1/modules/core/src/drawing.cpp:1680: error: (-215) box.size.width >= 0 && box.size.height >= 0 && thickness <= 255 in function ellipse

A simple try/catch, or check, in the right place should probably fix this.

Thank you for this package!

JimmyDaSilva commented 8 years ago

The crash happens only in debug mode so I will close this issue