Straightest Paths on Meshes By Cutting Planes

0 downloads 0 Views 3MB Size Report
Propagation”, In Proceedings of VLSM'03, 2003. 14. Polthier K., Schmies M.: “Straightest Geodesics on Polyhedral Surfaces”, Mathe- matical Visualization, 1998 ...
Straightest Paths on Meshes By Cutting Planes Sungyeol Lee, Joonhee Han and Haeyoung Lee Hongik University, Dept. of Computer Engineering, 72-1 Sangsoodong Mapogu, Seoul Korea 121-791 {leesy, hanj, leeh}@cs.hongik.ac.kr

Abstract. Geodesic paths and distances on meshes are used for many applications such as parameterization, remeshing, mesh segmentation, and simulations of natural phenomena. Noble works to compute shortest geodesic paths have been published. In this paper, we present a new approach to compute the straightest path from a source to one or more vertices on a manifold mesh with a boundary. A cutting plane with a source and a destination vertex is first defined. Then the straightest path between these two vertices is created by intersecting the cutting plane with faces on the mesh. We demonstrate that our straightest path algorithm contributes to reducing distortion in a shape-preserving linear parameterization by generating a measured boundary.

1

Introduction

Fig. 1. Straightest paths from a source to every vertex on the boundary as determined by our method. Models are Nefertiti on the left and an Ear on the right.

2

S. Lee, J. Han and H. Lee

Calculating geodesic paths and distances on meshes is a fundamental problem in various graphics applications such as parameterization [10], remeshing [6, 13, 18], mesh segmentation [18], and simulations of natural phenomena [15, 9]. Noble works to compute shortest geodesic paths and distances have been presented [12, 1, 7, 19]. An algorithm for straightest geodesic paths [14] was first proposed by Polthier and Schmies. Their straightest geodesics are well defined with the initial condition (a source and direction) but not with boundary conditions (a source and a destination). The straightest path may not be the same as the shortest path on meshes and may be more appropriate for some applications like wave propagation [15] or parameterization [10] for texture mapping. In this paper, we present a new and simple algorithm to compute straightest paths and distances between two vertices on manifold meshes with a boundary as shown in Figure 1. Our straightest path algorithm enables us to create a measured boundary for a linear parameterization and hence reduces distortion more than the parameterization with a fixed boundary as shown in Figure 3 and 4. 1.1

Related Work

There are several algorithms for geodesic computations on meshes, mostly based on shortest paths with boundary conditions i.e., source and destination vertices. Derived from Dijkstra’s algorithm, The MMP algorithm [12] is introduced to compute an exact shortest geodesic path. The CH algorithm [1] also allows the user to compute an exact shortest path with faster processing. Their implementation and extension are also proposed by [5, 6, 19] but they are still considered hard to implement. The Fast Marching algorithm by [7] computes an approximate geodesic path on meshes and has been used for remeshing and parameterization [18, 13]. However, it requires special processing for triangles with obtuse angles. A detailed overview of this approach can be seen in [11]. Another approach is to compute the straightest geodesic path. Polthier and Schimes [14] presented an algorithm to compute a straightest geodesic path on a mesh. They extended the notion of straight lines from the Euclidean plane onto the surface. It is uniquely defined with a source and direction. However it is not always defined between a source and a destination and also requires special handling of the swallow tails created by conjugate vertices [15] and triangles with obtuse angles [9]. Our method in this paper is designed to compute straightest paths between a source and one or more vertices on manifold meshes with a boundary.

2

Our Straightest Path Algorithm with Cutting Planes

We present a new and simple algorithm to compute a straightest path from a source to one or more destinations on a genus-0 surface patch. Figure 2 explains our simple steps to compute a straightest path between a source S and a destination D.

Straightest Paths on Meshes By Cutting Planes

3

P

B

S

P

S

S S

D

D

B

D

(a)

(b)

(c)

(d)

Fig. 2. Our straightest path algorithm: (a) The base plane B at the the source S is generated. (b) A plane P with S and D, which is vertical to B, is generated. (c) P cuts the mesh at intersection faces. Each green face is a result of cutting the mesh by the plane P. Red intersection vertices on green faces are then calculated and connected for our straightest path as shown in (d).

1. Specify a center S which is the point of origin and determine the vertex normal at S as follows: - Make virtual edges from S to every boundary vertex of the mesh. - Make virtual faces around S with these virtual edges. - Average normal vectors of virtual faces around S and assign it to the vertex normal vector at S. Then design the base plane B at S with the above vertex normal. 2. Find a plane P (vertical to B ) where the line from S to D is. 3. Repeat the following two sub-steps until it reaches D. - Find a face by intersecting the mesh with the cutting plane P at the starting vertex. - Find a line segment by calculating an intersection vertex on the face and connecting it to the starting vertex. Two planes always intersect in a line as long as they are not parallel. Our cutting plane P pierces each green face on the mesh. Therefore there is a unique line segment which is the straightest path by our method. The tangent a for a line segment can be easily calculated from the normal N1 of the green face and the normal N2 of the cutting plane P as follows: a = N1 XN2

(1)

The first green face intersecting with the cutting plane P can be easily found by searching only the 1-ring neighbor faces of the source S , the point of origin. Once you find the tangent a on the green face, the red intersection vertex is calculated and connected to S to produce the line segment. Then the red intersection vertex plays the role of a starting vertex to find the next green face. These processes should be repeated until the last red intersection vertex is D. The straightest distance from S to D is the sum of Euclidean distances of red line segments on the green faces. For multiple destinations from a source, the 2nd and 3rd steps in the above procedure are to be repeated for each destination.

4

S. Lee, J. Han and H. Lee

Figure 1 shows straightest paths by our new method from a source to boundary vertices on the models, Nefertiti on the left and the Ear on the right. Discussion The tangents of the previous straightest geodesics by Polthier and Schimes [14] are determined by gaussian curvatures at vertices and may be changed into random directions especially when the gaussian curvature is not 2π. As a result their straightest path from source may not be reached a destination. Our straightest path stays both on the cutting plane and on the mesh from the source to the destination. Therefore our straightest path can reach the destination. Our algorithm is output-sensitive to the number of intersection vertices to form a straightest path, which is a lot less than the total number of vertices on the mesh. Our method is linear to the total number of vertices, i.e., O(V) and does not require preprocessing of triangles with obtuse angles.

Fig. 3. Parameterization for Nefertiti with different boundaries: From the left, a square, a circle, and a measured using our straightest distances are used for the boundary. The final boundary is modified to a convex from the measured boundary. Notice less distortion near the measured boundary by our method.

3

Parameterization with a Measured Boundary

A 3D mesh parameterization provides a piecewise linear mapping between a 3D surface patch and an isomorphic 2D patch. It is a widely used or required operation for texture-mapping, remeshing, morphing or geometry imaging. Guaranteed one-to-one mappings that only requires a linear solver have been sought and many algorithms [3, 4, 8, 10] were proposed. To reduce inevitable distortions

Straightest Paths on Meshes By Cutting Planes

5

when flattening, a whole object is usually partitioned into several genus 0 surface patches. Generally the first step for parameterization is mapping boundary vertices to a fixed position. Usually the boundary is mapped to a square, a circle, or any convex shape while respecting the 3D-to-2D length ratio between adjacent boundary vertices. As long as the boundary vertices are mapped to a convex shape, the resulting mapping will be guaranteed to be one-to-one. The 2D embedded positions of the interior vertices are then found by solving a linear system. The linear system is generated with coefficients in a convex combination of 1-ring neighbors for each interior vertex. These coefficients characterize a shape-preserving property. This approach primarily concentrates on how to determine these coefficients. However as shown in Figure 3 and 4, high distortion occurs near the boundary. To reduce it, a free boundary [2] with a non-linear functional and a virtual boundary [8] with layers of additional vertices have been proposed. In this paper, we attempt to derive a measured boundary, linearly and without additional vertices, by our straightest path algorithm to reduce distortions. Straightest paths and distances from a center S to every boundary vertex of the mesh can be measured as follows: 1. Make virtual edges from S to every boundary vertex of the mesh. 2. Map each virtual edge onto the base plane B by a polar map, which preserves angles between virtual edges such as [3] (see for Figure 2 (a)). 3. Measure the straightest distance for each virtual edge on B from S to each boundary vertices with corresponding cutting planes. 4. Position each boundary vertex at the corresponding distance from S on B. Any previous parameterization can be applied and we choose to use [10]. Our straightest path contributes to deriving measured boundaries, reducing distortion, and much better texture-mapping as shown in Figure 3 and 4. The measured boundary is however dependent on the user-specified source S because a different choice of the source S generates different base plane B and different distances to boundary vertices. The center of the mesh is chosen for S by our experiments. Models Nefertiti Face Mountain

No. of LTD’s [10] LTD’s [10] Vertices fixed bound. measured bound. 299 1547 2500

1.165 1.591 1.552

1.152 1.341 1.436

Table 1. Distortion measured by the texture stretch metric [17]: [10] is used for parameterization. The boundary is fixed to a circle. Our straightest path algorithm is used for measured boundaries and reduces distortion.

6

S. Lee, J. Han and H. Lee

Fig. 4. More parameterization with different boundaries. Models are Face in the two left columns and the Mount on the two right columns. Notice less distortion near the measured boundary of each model.

4

Results

The visual results by our method are shown in Figure 1 for straightest paths from a source to boundary vertices. Figure 3 and 4 also demonstrate visual results by using our straightest paths. The distortion with the texture-stretch metric in [17] is also measured and shown in Table 1. Notice that a parameterization [10] with a measured boundary reduces distortion. The performance complexity of our algorithm is all linear to the number of vertices, i.e., O(V ). The longest processing time among our models in Table 1 is 0.53 sec, required for the Mountain having the highest number of vertices. The processing time is measured on a laptop with a Pentium M 2.0GHz 1GB RAM.

5

Conclusion and Future Work

In this paper, we introduce a new and simple algorithm to compute straightest paths between two vertices on manifold meshes with a boundary. To our knowledge our work is the first algorithm to compute the straightest path with boundary conditions. A cutting plane with a source and a destination vertex is first defined. Then the straightest path between these two vertices is created by intersecting the cutting plane with faces on the mesh. We demonstrate the utility of our straightest path algorithm to derive a measured boundary for parameterizations. In the future, we will study to find straightest geodesic paths between two vertices on closed manifold meshes. Also we will extend the utility of our straightest path algorithm by applying it to other mesh processing techniques such as remeshing, subdivision, or simplification.

Straightest Paths on Meshes By Cutting Planes

7

Acknowledgement This work was supported by grant No. R01-2005-000-10120-0 from Korea Science and Engineering Foundation in Ministry of Science & Technology. Thanks to Caltech’s Applied Geometry Lab. and Postech’s Computer Graphics Lab. for Models, Nefertiti, Ear, Mount, and Face.

References 1. Chen J., Han Y.: “Shortest Paths on a Polyhedron; Part I: Computing Shortest Paths”, Int. J. Comp. Geom. & Appl. 6(2), 1996. 2. Desbrun M., Meyer M., Alliez P.: “Intrinsic Parameterizations of Surface Meshes”, Eurographics 2002 Conference Proceeding, 2002. 3. Floater M.: “Parametrization and smooth approximation of surface triangulations”, Computer Aided Geometric Design, 1997. 4. Floater M.: “Mean Value Coordinates”, Comput. Aided Geom. Des., 2003. 5. Kaneva B. O’Rourke J.: “An implementation of Chen and Han’s sortest paths algorithm”, Proc. of the 12th Canadian Conf. on Computational Geometry, 2000. 6. Kanai T., Suzuki H.: “Approximate Shortest Path on a Polyhedral Surface Based on Selective Refinement of the Discrete Graph and Its Applications”, Proc. Geometric Modeling and Processing 2000 (HongKong) 2000. 7. Kimmel R., Sethian J.A.: “Computing Geodesic Paths on Manifolds”, Proc. Natl. Acad. Sci. USA Vol.95 1998, 1998. 8. Lee Y., Kim H., Lee S.: “Mesh Parameterization with a Virtual Boundary”, Computer and Graphics 26 (2002), 2002. 9. Lee H., Kim L., Meyer M., Desbrun M.: “Meshes on Fire”, Computer Animation and Simulation 2001, Eurographics, 2001. 10. Lee H., Tong Y. Desbrun M.: “Geodesics-Based One-to-One Parameterization of 3D Triangle Meshes”, IEEE Multimedia January/March (Vol. 12 No. 1), 2005. 11. Mitchell J.S.B.: “Geometric Shortest Paths and network optimization”, In Handbook of Computational Geometry, J.-R. Sack and J. Urrutia, Eds. Elsevier Science 2000. 12. Mitchell J.S.B., Mount D.M., Papadimitriou C.H.: “The Discrete Geodesic Problem”, SIAM J. of Computing 16(4), 1987. 13. Peyr´e G., Cohen L.: “Geodesic Re-meshing and Parameterization Using Front Propagation”, In Proceedings of VLSM’03, 2003. 14. Polthier K., Schmies M.: “Straightest Geodesics on Polyhedral Surfaces”, Mathematical Visualization, 1998. 15. Polthier K., Schmies M.: “Geodesic Flow on Polyhedral Surfaces”, Proceedings of Eurographics-IEEE Symposium on Scientific Visualization ’99, 1999. 16. Riken T., Suzuki H.: “Approximate Shortest Path on a Polyhedral Surface Based on Selective Refinement of the Discrete Graph and Its Applications”, Geometric Modeling and Processing 2000 (Hongkong), 2000. 17. Sander P.V., Snyder J., Gortler S.J., Hoppe H.: “Texture Mapping Progressive Meshes”, Proceedings of SIGGRAPH 2001, 2001. 18. Sifri O., Sheffer A., Gotsman C. : “Geodesic-based Surface Remeshing”, In Proceedings of 12th Intnl. Meshing Roundtable, 2003. 19. Surazhsky V., Surazhsky T., Kirsanov D., Gortler S., Hoppe H.: “Fast Exact and Approximate Geodesics on Meshes”, ACM SIGGRAPH 2005 Conference Proceedings, 2005.