Skip to Content.
Sympa Menu

cgal-discuss - [cgal-discuss] Reply: Re: Poblems on Make_Mesh_3

Subject: CGAL users discussion list

List archive

[cgal-discuss] Reply: Re: Poblems on Make_Mesh_3


Chronological Thread 
  • From: 11硕博 隋伟 <>
  • To:
  • Subject: [cgal-discuss] Reply: Re: Poblems on Make_Mesh_3
  • Date: Fri, 31 Jul 2015 20:30:44 +0800 (GMT+08:00)


Thank  you for your timely reply. This is my code piece. I use the reconstructed Poisson function as the input of domain. It works for some data, but for some data with large missing, this problem occurs.

    /* make points with normals */
    PointList cPoints;
     make_points_with_normal(pc->points, std::back_inserter(cPoints),
                                CGAL::make_normal_of_point_with_normal_pmap(std::back_inserter(cPoints)) );

    /* Creates implicit function from the read points using the default solver.
     *  Note: this method requires an iterator over points
     * + property maps to access each point's position and normal.
     * The position property map can be omitted here as we use iterators over Point_3 elements.
     */
    Poisson_reconstruction_function function(cPoints.begin(), cPoints.end(),
                                             CGAL::make_normal_of_point_with_normal_pmap(cPoints.begin()) );
    /* Computes the Poisson indicator function f()  at each vertex of the triangulation.
     */
    if ( ! function.compute_implicit_function() )
        return EXIT_FAILURE;
    Sphere bsphere = function.bounding_sphere();

    // Domain (Warning: Sphere_3 constructor uses squared radius !)
    Mesh_domain domain(function,  bsphere);

    // Mesh criteria
    Mesh_criteria criteria(  edge_size = myCriteria.edge_size(),
                                             facet_angle = myCriteria.facet_angle(),
                                             facet_size = myCriteria.facet_size(),
                                             cell_radius_edge_ratio = myCriteria.cell_radius_edge_ratio(),
                                             cell_size = myCriteria.cell_size());

    // Add Features
    cout<<"Adding sharp features..."<<endl;
    Polylines polylines;
    /**** add some features*****/
    domain.add_features(polylines.begin(), polylines.end());

    cout<<"Run Delaunay refinement ..."<<endl;
    // Mesh generation without feature preservation
    C3t3 c3t3 = CGAL::make_mesh_3<C3t3>(domain, criteria);


> -----原始邮件-----
> 发件人: "Sebastien Loriot (GeometryFactory)" <>
> 发送时间: 2015年7月31日 星期五
> 收件人: 
> 抄送: 
> 主题: Re: [cgal-discuss] Poblems on Make_Mesh_3

> Without a minimal example showing the pb, it is hard to help.

> Sebastien.

> On 07/31/2015 02:16 PM, 11硕博    隋伟 wrote:
> >
> > Dear all
> >
> > I have encountered a problem when I run the Make_mesh_3 function in CGAL.
> > And the output is listed as below. Can anyone can help me?
> >
> > Thank you very much.
> >
> > (23,10,0,0) (121.7 vertices/s)
> >
> > Total refining surface time: 0.082236s
> >
> >
> > Start volume scan...Scanning triangulation for bad cells (sequential)...
> > 57 cells scanned, done.
> >
> > Number of bad cells: 6
> >
> > end scan. [Bad tets:6]
> >
> >
> > Refining...
> >
> > Legend of the following line: (#vertices,#steps,#facets to refine,#tets
> > to refine)
> >
> > (23,0,0,6)terminate called after throwing an instance of
> > 'CGAL::Assertion_exception'
> >
> > what(): CGAL ERROR: assertion violation!
> >
> > Expr: !r_tr_.is_infinite(*cell_it)
> >
> > File: ../../../myLibs/CGAL-4.6.1/include/CGAL/Mesh_3/Refine_cells_3.h
> >
> > Line: 867
> >
> > The program has unexpectedly finished.
> >
> >
> >
> >
> >


> -- 
> You are currently subscribed to cgal-discuss.
> To unsubscribe or access the archives, go to
> https://sympa.inria.fr/sympa/info/cgal-discuss








Archive powered by MHonArc 2.6.18.

Top of Page