Subject: CGAL users discussion list
List archive
- From: Rob Patro <>
- To:
- Subject: Re: [cgal-discuss] Progressive Mesh
- Date: Mon, 26 Jan 2009 14:24:05 -0500
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:from:user-agent:mime-version:to:subject:references :in-reply-to:x-enigmail-version:content-type :content-transfer-encoding; b=fR4XycCSkaqCNo6vFWWt0zZJFRJ228PDMqRVT5MTm2MvPyHH1Bhlvwaqo+5hW+ee5a SJYdxfHcqDnPqxal1Ub4wZLuocf+9dnTR+3hDc4wM42Jzn3aF6hzx41zklCF+VEMB8w3 O2f/0GPD1s9g0HjEuRJY2S+Mu6k6UpIvpZ8/0=
Thanks Andreas,
I can't believe I missed that. It looks like a PM should be pretty
easy to implement using this framework. I seem to be having a bit of a
problem though. Going along with the example to which you pointed me,
say that I want to maintain a vector of the collapsed
edges. The OnCollapsing function in the visitor takes a Profile
parameter. I tried modifying it thusly:
// Called during the processing phase for each edge being collapsed.
// If placement is absent the edge is left uncollapsed.
void OnCollapsing(Profile const& prof,
boost::optional<Point_3> placement){
if ( placement ){
_edge_profiles.push_back(prof);
++ collapsed;
}else{
++ placement_uncomputable;
}
}
I also added a "std::vector<Profile> _edge_profiles" to the Visitor
class. From what I could figure out from the documentation, Profile
should have a member .v0v1 and .v1v0 that will return
handles/descriptions to the collapsed halfedges. However, when I try to
access this method, the compiler tells me:
error: ‘class
CGAL::Surface_mesh_simplification::Edge_profile<CGAL::Polyhedron_3<CGAL::Simple_cartesian<double>,
m3_items, CGAL::HalfedgeDS_default, std::allocator<int> > >’ has no
member named ‘v0v1’
I realize that this might be a little sparse, but the rest of my code is
very similar to the example. Any help you could provide me on this
would be greatly appreciated.
Thanks,
Rob
Andreas Fabri wrote:
>
> Hi Rob,
>
> Note that the mesh simplification algorithm has the notion of
> an EdgeCollapseSimplificationVisitor
>
> http://www.cgal.org/Manual/3.4/doc_html/cgal_manual/Surface_mesh_simplification_ref/Concept_EdgeCollapseSimplificationVisitor.html#Cross_link_anchor_1340
>
>
> This allows you to keep track of which edges get contracted.
>
>
>
> In the example section of the User Manual
> http://www.cgal.org/Manual/3.4/doc_html/cgal_manual/Surface_mesh_simplification/Chapter_main.html#Subsection_42.4.2
>
>
> the second example entitled "Example Using an Enriched Polyhedron"
> even shows how to use/implement such a visitor.
>
> Best regards,
>
> andreas
>
>
> Rob wrote:
>> Pierre,
>>
>> Thank you very much for pointing me in this direction. I've never
>> used VTK before, and so hadn't thought to conduct that search. I'd
>> always assumed it was geared toward volume data, which is why I didn't
>> think to look. Upon further inspection, I stumbled across this thread
>> (http://markmail.org/message/rgq35pb2p66x7nez). Though this too is a
>> bit outdated (from 2004), it seems to suggest that obtaining the actual
>> progressive mesh information, rather than just the decimated mesh, might
>> be difficult to do. Either way, I'll look into VTK more to see how
>> difficult obtaining the list of performed edge collapses might be. If
>> not, it seems that CGAL provides all the necessary Euler operations to
>> perform the decimation myself, in which case I could maintain the
>> necessary info on the edge collapses and vertex splits. Would anyone
>> else using CGAL be interested in an implementation of progressive meshes
>> (if it turns out not to be patented by Microsoft)?
>>
>> Cheers,
>> Rob
>>
>>
>> Pierre JUILLARD wrote:
>>> I see however that the publication is a little bit old...
>>> VTK is now at version 5.2.1
>>>
>>>
>>> Cheers,
>>>
>>> Pierre
>>>
>>>
>>>
>>> 2009/1/25 Pierre JUILLARD
>>> <>
>>>
>>>
>>>> Ok, so I come back with another suggestion.
>>>>
>>>> I had a look on the link you gave me and looked at the movies.
>>>> It is actually a behaviour of ParaView which you may know (open source
>>>> software base on VTK for scientific data visualization):
>>>> http://www.paraview.org/
>>>>
>>>> I indeed noticed that when I was making a 3D mesh rotate, such
>>>> simplifications were carried out (most probably to decrease the CPU
>>>> load).
>>>> As this software is based on VTK, I simply typped in Google: "vtk
>>>> progressive mesh", and I found many results.
>>>> You should tried.
>>>>
>>>> I most notably found this paper (Mesh Decimation Using VTK) which
>>>> describe
>>>> the classes in VTK allowing mesh decimation:
>>>> http://www.cg.tuwien.ac.at/courses/Seminar/SS2002/Knapp_paper.pdf
>>>>
>>>> If you want to have a close look on these classes, I would recommend
>>>> going
>>>> to the doxygen documentation:
>>>> http://www.vtk.org/doc/nightly/html/classes.html
>>>>
>>>> Regards,
>>>>
>>>> Pierre
>>>>
>>>>
>>>> 2009/1/24
>>>> <>
>>>>
>>>> Pierre,
>>>>
>>>>> Thanks for the suggestion, but this is not really what I mean by
>>>>> the term
>>>>> progressive mesh. Rather, what I meant was the progressive mesh
>>>>> structure
>>>>> introduced by Hoppe
>>>>> (http://research.microsoft.com/en-us/um/people/hoppe/proj/pm).
>>>>> Basically, the
>>>>> reason I asked on the CGAL discuss list is because it seems like CGAL
>>>>> takes on
>>>>> part of the way to implementing this structure. Namely, they
>>>>> provide the
>>>>> EdgeCollapsable mesh concept. I was just curious how difficult it
>>>>> would
>>>>> be to
>>>>> implement and properly keep track of the edge collapses and to
>>>>> reintroduce
>>>>> removed vertices with a vertex split. I also wanted to see if
>>>>> anyone else
>>>>> had
>>>>> done this, as I see no real use in re-inventing the wheel.
>>>>>
>>>>> Thanks,
>>>>> Rob
>>>>> --
>>>>> You are currently subscribed to cgal-discuss.
>>>>> To unsubscribe or access the archives, go to
>>>>> https://lists-sop.inria.fr/wws/info/cgal-discuss
>>>>>
>>>>>
>>>>
>>
>
- Re: Re: [cgal-discuss] Progressive Mesh, (continued)
- Re: Re: [cgal-discuss] Progressive Mesh, rob.patro, 01/24/2009
- [cgal-discuss] Polyhedron demo problem, Rob, 01/24/2009
- Re: [cgal-discuss] Polyhedron demo problem, Laurent Rineau (GeometryFactory), 01/25/2009
- Re: [cgal-discuss] Polyhedron demo problem, Rob, 01/25/2009
- Re: [cgal-discuss] Polyhedron demo problem, Laurent Rineau (GeometryFactory), 01/26/2009
- Re: [cgal-discuss] Polyhedron demo problem, Rob, 01/26/2009
- Re: [cgal-discuss] Polyhedron demo problem, Laurent Rineau (GeometryFactory), 01/26/2009
- Re: [cgal-discuss] Polyhedron demo problem, Rob, 01/25/2009
- Re: [cgal-discuss] Polyhedron demo problem, Laurent Rineau (GeometryFactory), 01/25/2009
- Re: Re: [cgal-discuss] Progressive Mesh, Pierre JUILLARD, 01/25/2009
- Re: Re: [cgal-discuss] Progressive Mesh, Pierre JUILLARD, 01/25/2009
- Re: [cgal-discuss] Progressive Mesh, Rob, 01/25/2009
- Re: [cgal-discuss] Progressive Mesh, Andreas Fabri, 01/25/2009
- Re: [cgal-discuss] Progressive Mesh, Rob Patro, 01/26/2009
- Re: [cgal-discuss] Progressive Mesh, Fernando Cacciola, 01/26/2009
- Re: [cgal-discuss] Progressive Mesh, Rob, 01/27/2009
- Re: [cgal-discuss] Progressive Mesh, Rob Patro, 01/27/2009
- Re: [cgal-discuss] Progressive Mesh, Fernando Cacciola, 01/27/2009
- Re: [cgal-discuss] Progressive Mesh, Fernando Cacciola, 01/28/2009
- Re: [cgal-discuss] Progressive Mesh, Rob Patro, 01/28/2009
- Re: [cgal-discuss] Progressive Mesh, Fernando Cacciola, 01/28/2009
- Re: [cgal-discuss] Progressive Mesh, Rob Patro, 01/28/2009
- Re: [cgal-discuss] Progressive Mesh, Fernando Cacciola, 01/28/2009
- Re: [cgal-discuss] Progressive Mesh, Rob Patro, 01/29/2009
- Re: [cgal-discuss] Progressive Mesh, Andreas Fabri, 01/25/2009
- Re: [cgal-discuss] Progressive Mesh, Rob, 01/25/2009
- Re: Re: [cgal-discuss] Progressive Mesh, Pierre JUILLARD, 01/25/2009
- [cgal-discuss] Polyhedron demo problem, Rob, 01/24/2009
- Re: Re: [cgal-discuss] Progressive Mesh, rob.patro, 01/24/2009
Archive powered by MHonArc 2.6.16.