Skip to Content.
Sympa Menu

cgal-discuss - [cgal-discuss] CGAL alpha shape example - segmentation fault

Subject: CGAL users discussion list

List archive

[cgal-discuss] CGAL alpha shape example - segmentation fault


Chronological Thread 
  • From: irene89 <>
  • To:
  • Subject: [cgal-discuss] CGAL alpha shape example - segmentation fault
  • Date: Sun, 20 Nov 2016 09:27:43 -0800 (PST)
  • Authentication-results: mail2-smtp-roc.national.inria.fr; spf=None ; spf=SoftFail ; spf=None
  • Ironport-phdr: 9a23:Jh0NjB9fYOrP3v9uRHKM819IXTAuvvDOBiVQ1KB+2+kcTK2v8tzYMVDF4r011RmSDN6dsagP0rKP++C4ACpbvsbH6ChDOLV3FDY7yuwu1zQ6B8CEDUCpZNXLVAcdWPp4aVl+4nugOlJUEsutL3fbo3m18CJAUk6nbVk9EM2uRN+X1pz/l7vqo9yAKzlP0TGyaLc3IBStphjKreEXh5FjI+A/0EjnuHxNLuVMyGVldQPbyxfm4cGi+rZs9i1Rv7Qq8MsWAvayRLgxUbENVWduCGsy/sC+7kGbQA==

Hi everybody, I'm new to C++ and CGAL. I'm tryng to obtain an alpha shape
from a point set in the plane and to do that I was first trying to run the
following example:

http://doc.cgal.org/latest/Alpha_shapes_2/Alpha_shapes_2_2ex_alpha_shapes_2_8cpp-example.html

with this set of point:
(0,2), (-0.5,1), (0,1), (0.5,1), (-2,0), (-1,0), (0,0), (1,0), (2,0),
(-0.5,-1), (0,-1), (0.5,-1), (0,-2)

The points are saved in a file data.txt with the same exact format above and
this file is in the same directory of the .cpp. Obviously I changed the line
in the example

std::ifstream is("./data/fin", std::ios::in);

with the line

std::ifstream is("data.txt", std::ios::in);

I compiled with
g++ prova.cpp -lCGAL -lgmp
and all went ok, but when I run it I had this error:

Reading 0 points from file
Alpha Shape computed
0 alpha shape edges
Segmentation fault (core dumped)

Any idea?
Thanks in advance for helping!



--
View this message in context:
http://cgal-discuss.949826.n4.nabble.com/CGAL-alpha-shape-example-segmentation-fault-tp4662370.html
Sent from the cgal-discuss mailing list archive at Nabble.com.



Archive powered by MHonArc 2.6.18.

Top of Page