alecjacobson / gptoolbox

Matlab toolbox for Geometry Processing.
MIT License
628 stars 166 forks source link

Mesh parameterization in gptoolbox #11

Closed alecjacobson closed 8 years ago

alecjacobson commented 8 years ago

From personal email...

Hey, I am now an undergraduate student majoring in mathematics, and my thesis is about mesh parameterization. I found your project on github and it is really helpful! But I have some questions about the gptoolbox which I cannot find the answer on both README.md and the documents, I sincerely hope that you can help me with that.

In the lscm.m, you said: % first need to convert each triangle to its orthonormal basis, if coming from 3D assert(dim == 2); But I have no idea how to convert an 3D mesh(V,F) into a 2D mesh, how to convert an n_3 matrix V into an n_2 matrix? Which function should I use to implement that?

Another question is about the boundary_conditions.m

% Compute boundary and boundary conditions for solving for correspondences
%weights over a set of mesh (V,F) with control points C(p,:) and control
% bones C(E(:,1),:) --> C(E(:,2),:) 

What principle should I obey when I am selecting the control points?

alecjacobson commented 8 years ago

The limitation of lscm to 2D meshes was entirely artificial. Just now I've pushed a new version that is based on another paper (doing the same thing) which is easier to implement for 3D surfaces.

Regarding choosing the fixed points, this is a drawback of these type of parameterization papers that are so sensitive to the choice of fixed points and their arrangement in the plane. More advanced/recent methods will also try to optimize the boundary mapping or rather allow the boundary to move freely in the plane. I particularly like the recent work of Smith and Schaefer called "Bijective Parameterization with Free Boundaries". Though I don't know if there's an implementation around.

proteuslinzk commented 8 years ago

Yeah, thanks for your answer!! the problem of calculating boundary conditions is drawing me crazy.

I've seen another way of calculating boundary, but that is an incomplete way. http://nbviewer.jupyter.org/github/gpeyre/numerical-tours/blob/master/matlab/meshdeform_1_parameterization.ipynb

https://github.com/gpeyre/numerical-tours/blob/master/matlab/toolbox_graph/compute_boundary.m