added function to retrieve the parametrization in matrix form
This commit is contained in:
parent
155806f53e
commit
a75dbdc05d
|
@ -202,6 +202,22 @@ public:
|
|||
}
|
||||
}
|
||||
|
||||
static void GetUVData(const MeshType &mesh,
|
||||
MatrixXm & uv)
|
||||
{
|
||||
tri::RequireVertexCompactness(mesh);
|
||||
tri::RequirePerVertexTexCoord(mesh);
|
||||
|
||||
uv = MatrixXm(mesh.VN(), 2);
|
||||
|
||||
// per vertices uv
|
||||
for (int i = 0; i < mesh.VN(); i++)
|
||||
{
|
||||
uv(i,0) = mesh.vert[i].cT().U();
|
||||
uv(i,1) = mesh.vert[i].cT().V();
|
||||
}
|
||||
}
|
||||
|
||||
// get edge to face and edge to vertex adjacency
|
||||
static void GetTriEdgeAdjacency(const MeshType &mesh,
|
||||
Eigen::MatrixXi& EV,
|
||||
|
|
Loading…
Reference in New Issue