Local Ops: Tweaking the Surfaces of Faces   

<<< Local Ops: Creating Surfaces to Attach to Faces Chapters Local Ops: Transforming Faces >>>

Contents

[back to top]


17.1 Introduction

PK_FACE_replace_surfs_3 tweaks the surfaces of selected faces, by deleting and replacing the existing surfaces with a new list of surfaces which you have created. The list of faces can consist of one or more faces. This function only works on solid bodies, and does not work for a face with no surface geometry.

[back to top]

17.1.1 Tweaking a single face

You can use PK_FACE_replace_surfs_3 to change the diameter of a hole, as in the following example:

 

Figure 17-1 Tweaking a single face

[back to top]

17.1.2 Tweaking a list of faces

You can use PK_FACE_replace_surfs_3 to change the top (planar) face of a cylinder to a sphere and change its cylindrical face to a truncated cone, in the same operation.

 

Figure 17-2 Tweaking a list of faces

[back to top]


17.2 Merging adjacent faces

Sometimes, replacing the surfaces of selected faces means that adjacent faces that were previously not mergeable can now be merged. You can control whether or not such merging is performed using the merge option (PK_replace_merge_t) in PK_FACE_replace_surfs_o_t. This option can take the following values:

 

Value Description

PK_replace_merge_no_c

Do not merge any adjacent faces that become mergeable. This is the default.

Note: Merging may still occur if healing is necessary to ensure integrity of the final part.

PK_replace_merge_in_c

If adjacent faces become mergeable, merge them only if they were supplied in the original function call.

Vertices on the boundary of a merged face are merged if possible, though additional faces are not merged in order to achieve this.

PK_replace_merge_out_c

Merge adjacent faces that become mergeable if the faces either:

  • were supplied in the original function call
  • share a common edge with a face supplied in the original function call

Vertices on the boundary of a merged face are merged if possible, though additional faces are not merged in order to achieve this.

Note: Faces are not merged if they are not in the supplied set of faces, and share only a common vertex with a face in the supplied set of faces

This is illustrated in Figure 17-3.

 

Figure 17-3 Merging adjacent faces when replacing surfaces

[back to top]


17.3 Shared geometry after replacing surfaces

Figure 17-4 shows a block with two slots where four faces share a single planar surface. Tweaking one of the four faces that share the top planar surface, independently of the others, results in that face being detached from the original shared surface and therefore given a new surface. The remaining three faces still share the original geometry. The same applies to the shared curves.

 

Figure 17-4 Shared surface after a PK_FACE_replace_surfs_3 operation

[back to top]


17.4 Why replacing surfaces can fail

PK_FACE_replace_surfs_3 allows a wide range of topology changes. However, there are a number it cannot handle. The following attempted operations, illustrated using the previous examples, fail for the reasons as explained.

This following operation fails because the edges at the top and bottom cannot be recalculated. This is because the cylindrical surface no longer intersects the top/bottom faces.

 

Figure 17-5 Change in topological relationship between top face and hole

This following operation fails because the face of the hole has been tweaked to such an amount that it has split the planar faces, thereby creating two solids in the model.

 

Figure 17-6 Topological change - hole splits the planar faces

This following operation fails because the tweak that was applied to the cylindrical face would result in a pointed cone being created. The edge at the bottom of the cylinder cannot be recalculated since the new surface (cone) does not intersect the bottom (planar) face.

 

Figure 17-7 Topological change - the bottom planar face has been deleted

To successfully complete the previous three examples you need to use boolean operations.

 

[back to top]

<<< Local Ops: Creating Surfaces to Attach to Faces Chapters Local Ops: Transforming Faces >>>