• 沒有找到結果。

Cutting region construction

在文檔中 網格分割轉換 (頁 49-57)

Segmentation Transfer

5.4 Cutting region construction

ary, we trace along the link to find the first matched MSP gradient boundaries in up and down direction. If no matched MSP gradient boundary is found, we use LR value of the start or end points (0.0 or 1.0) of the link. Then use the mapping relation to find the corresponding MSP gradient boundaries on the target link. As shown in figure 5.3, we compute the distance (LR value difference) between these boundaries. Then the LR value on the target link can be computed according to the same proportional relation.

Figure 5.3: The position of the target boundary can be inferred from the adjacent matched MSP gradient boundaries.

After the above process, for each source boundary we obtain the LR value on the target link.

It represents its approximate location on the target mesh.

5.4 Cutting region construction

We have obtained the LR values which can infer the located points on the target link. However, it is not sufficient since the source boundary have some additional characteristics needed to be

5.4 Cutting region construction 38

considered. We observe that the cross orientation of the boundary’s fitting plane (section 5.2) and link is an important feature to globally describe the shape of the boundary. For example, some boundaries may cross the link vertically and form the short, straight shapes. And other boundaries may cross the link with non-vertical angles and produce more tilted, longer shapes.

Another important feature is the surface extent covered by boundary. Some boundaries have small extents which mean the points of the boundaries are quite close to their fitting planes.

And some boundaries may cover relatively wide extents so that they have large deviations to the fitting planes.

We take into account these two features to develop our algorithm which establishes the boundary’s extent on the target mesh surface. We denote it as the cutting region of the boundary.

The cutting region can be established in three steps. In step one we compute the normal of the source fitting plane then transfer it to the target link for building the corresponding target fitting plane. In step two the planar slice of the mesh and fitting plane is constructed and become the initial location of the cutting region. Finally in step three we consider the extent covered by source boundary, and expand the target cutting region to make it have similar extent as source.

The normal of the source fitting plane can be computed easily. But they can not be directly copied to the target space since the source and target meshes may have different orientations in the original 3D space. We solve the issue by establishing the consistent local coordinate systems on both sides of the source and target links, then transferring plane normals through the coordinate systems. The consistent coordinate system can be established in five steps as shown in figure 5.4.

5.4 Cutting region construction 39

(a) (b)

(c) (d)

(e)

Figure 5.4: The process of establishing consistent local coordinate systems on the source and target links. Where red, green, blue line represent x, y, and z axes, respectively.

First, for the current source link, we get the junction skeleton node connected the link and set it as the origin of the local coordinate system. The x axis is the local direction of the

5.4 Cutting region construction 40

current link(section 4.3.2). The y axis is the local direction of another link connected to original junction node. Second, the z axis is the cross product of the x and y axes, and y axis is reset as the cross product of the z and x axes to form the orthogonal coordinate system. Third, the source coordinate system is transferred to the corresponding target node by using the shape matching technique(section 4.3.2). Fourth, the orientation of the target coordinate system is adjusted by aligning the x axis to the local direction of the current target link. Finally, the coordinate systems are moved from junction nodes to the points located by LR value, the orientations are adjusted according the local directions of the links.

We denote Ns as the normal of the source fitting plane, Ms and Mt as the transformation matrixes from original 3D space to the source and target local coordinate system, respectively.

The normal of the target fitting plane Nt can be computed by using a linear transformation:

Nt = Mt−1∗ MS∗ Ns.

We define a planar intersection as the slice caused by the fitting plane and mesh. It contains a series of line segments crossing the polygons of the mesh. For the source and target meshes, we respectively construct the planar intersections of their fitting planes, as shown in figure 5.5. For most of the positions on the link, the generated planar intersections are close to the boundaries and are suitable to be the initial cutting region, just like figure 5.5(a-b). Except the junction of the two parts, some proportions of the planar intersection will belong to areas which do not correspond to the current link. As shown in figure 5.5(c-d), the fitting planes cut the trucks and cause the large, inappropriate planar intersections. For this case we must perform intersection reduction, which removes the proportions of the planar intersections which belong to other parts and reconnects the gaps. Although we know that these proportions are always far from the current links, it is still hard to correctly process intersection reduction since using distances to identify the removed proportions is not a robust way.

5.4 Cutting region construction 41

(a) (b)

(c) (d)

Figure 5.5: The planar intersections of the meshes and fitting planes. The intersections and boundaries are colored in red and green, respectively: (a-b) common position, (c-d) junction of the two parts

We thus take a different approach to deal with the intersection reduction. The distance information of the points of source boundary to the links is utilized to construct the planar intersections through the following processes. First, the source boundary are projected on its fitting plane. The origin and the x, y, z axes of the local coordinate system are also projected.

5.4 Cutting region construction 42

We use the longest projected axis as the start ray and rotate it around the normal of the fitting plane to generate several sample rays, as shown in figure 5.6(a-b). The number of the sample rays affects the accuracy of the boundary description. But in practice we found that even a few samples could achieve good results. The number is set to 16 in all of our experiments. Each sample ray is performed the ray-boundary intersection in the fitting plane domain to obtain the intersecting point Pi (note that it may be inside the mesh) and distance. And it casts a point Pa

on the mesh which represents the sample of the original planar intersection. We additionally generate two rays which start at Pi and parallel to the normal and inward normal of the fitting plane. They cast two points on the mesh called Pband Pcwhich represent the best fitting points by distance information of the boundary. For each sample ray a final sample point is chosen from one of the Pa, Pb, and Pcwhich has minimum distance to the current link (The origin in figure 5.6(c)). Finally the reduced planar intersection is constructed by using the geodesic paths to connect all the adjacent sample points. The idea of this method is that, when fitting plane is located at the junction of two parts, the mesh surfaces may be nearly parallel to the fitting plane.

So it causes the intersections(Pa) which has large distance to the link(see figure 5.5(c-d)). In this case the points generated by distance information of the boundary (Pbor Pc) are substituted for these proportions. Actually, in most of the case these points are very close to the fitting plane. On the other hand, when fitting plane is located at the common positions, the normal of the fitting plane will be more parallel to the link (see figure 5.5(a-b)), so the points Pb and Pc will have larger distance then Pa.

5.4 Cutting region construction 43

(a) (b) (c)

Figure 5.6: Intersections reduction by ray sampling: (a) boundary on the mesh, (b) sample rays on the fitting plane, (c) a diagram showing a sample ray generates three candidate points: Pa, Pband Pc

The processes of the target intersection reduction are similar to source. Except the length of the sample rays which need to be provided from source (target mesh has no boundary). The ratio of the local MSP values of source to target links is computed and the lengths of the source sample rays are scaled and transferred to the target.

In fact, during the intersection reduction we do not really compute the geodesic paths. In-stead we simply perform Dijkstra algorithm on the dual graph of the mesh to generate the face lists between the adjacent sample points. Figure 5.7 shows an example of the original and reduced planar intersection. We can see that both of the planar intersections are quite reduced.

5.4 Cutting region construction 44

(a) Source. (b) Target.

Figure 5.7: The original planar intersections colored in red, and the reduced planar intersec-tyions colored in blue.

Now the reduced planar intersections are expanded to become the cutting regions of the boundaries. For the source we set the distance of each face centroid on the planar intersections to zero, and run Dijkstra algorithm to gradually add adjacent faces to the cutting region until all the one-ring vertices of the source boundary are included in it. The maximum expanding distance of source is recorded, scaled by the ratio of the longest geodesic path of source to target meshes, and used to expand the target cutting regions. Figure 5.8 shows an example of the source and target cutting regions.

(a) Source. (b) Target.

Figure 5.8: An example of the source and target cutting regions.

在文檔中 網格分割轉換 (頁 49-57)

相關文件