gylns / cvblob

Automatically exported from code.google.com/p/cvblob
GNU Lesser General Public License v3.0
0 stars 0 forks source link

Failed at cvb::cvRenderContourChainCode when input image has blobs made of 1 pixel #13

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. The input image has blobs made of 1 pixel.
2.
for (cvb::CvBlobs::iterator it = blobs.begin(); it != blobs.end(); it++)
{
    cvb::CvBlob* blob = it->second;
    cvb::CvContourChainCode cc = blob->contour;
        cvb::CvContourPolygon* polygon = cvb::cvConvertChainCodesToPolygon(&cc); // Debug assertion failed!

What is the expected output? What do you see instead?
When dealing with 1-pixel area blobs, the method cvConvertChainCodesToPolygon 
exits unexpectedly, with the message: 

---
Debug Assertion Failed!

Program: ...cuments\Visual Studio 2010\Projects\CppTest\Debug\CppTest.exe
File: c:\program files\microsoft visual studio 10.0\vc\include\list
Line: 207

Expression list iterator not dereferencable

---

What version of the product are you using? On what operating system?
cvblob-0.10.1
OpenCV 2.1
Visual Studio 2010
Windows 7

Thanks again for your great work!

Original issue reported on code.google.com by schim...@gmail.com on 12 Aug 2010 at 9:43

GoogleCodeExporter commented 9 years ago
It seems that I fixed this bug time ago and forgot to update this entry :-S

Thank you very much for your report! It's really helpful for me!

Original comment by grendel....@gmail.com on 23 Nov 2010 at 10:18