PK_ERROR_code_t PK_FACE_replace_surfs_2 ( --- received arguments --- int n_faces, --- number of faces const PK_FACE_t faces[], --- faces const PK_SURF_t surfs[], --- replacement surfaces const PK_LOGICAL_t senses[], --- surface orientation double tolerance, --- tolerance for operation const PK_FACE_replace_surfs_o_t *options, --- options --- returned arguments --- PK_TOPOL_track_r_t *const tracking, --- tracking information PK_FACE_replace_surfs_r_t *const results --- status information ) This function replaces the geometry of the given faces with the supplied surfaces. NOTE: This function supersedes PK_FACE_replace_surfs, which is now obsolete. Specific Errors: PK_ERROR_tool_faces_many_bodies faces do not belong to a single body PK_ERROR_not_implemented user options not implemented Introduction All geometry of the given faces is replaced by the given geometry in surfs. The surface orientation with respect to the face is specified by the logical value in senses. The number of surfaces and sense flags passed to the function, via the surfs and senses arguments, must be identical to the number faces in the faces array. The geometry of the edges and vertices connected to the modified faces will be deleted and recalculated. Where edges are adjacent to faces whose geometry is being replaced, the edge curves are re-computed as the intersection of the face surfaces. Where edges or faces (sharing a vertex or edge at the boundary of the faces to be modified) have geometry which is inextendable, it may not be possible to recalculate vertices or edges. This is because the curve or surface do not intersect the new surface. If such edges have a user defined tolerance, this is likely to occur since SP-curves are inextendable. If the given faces are on a sheet body, they must not share an edge with any rubber faces. Surface Sense Parameter The sense flag for a particular face/surface combination is interpreted as follows : o PK_LOGICAL_true When the new surface is attached to the face, the face normal must be in the same direction as the natural surface normal (as calculated by the function PK_SURF_eval_with_normal). o PK_LOGICAL_false When the new surface is attached to the face, the face normal must be in the opposite direction to the natural surface normal (as calculated by the function PK_SURF_eval_with_normal). Checking options The extent to which checking is applied to the body is specified by the check_fa_fa field of the option structure. At present check_fa_fa field can only be used to turn on or off face-face checking, by setting it to PK_check_fa_fa_yes_c or PK_check_fa_fa_no_c respectively. If face-face checking is turned on, then face-face checks are done on the body in addition to default checks. For most applications face-face checking will be tuned off, which will give an adequate level of checking. Tracking Information The function returns tracking information relating to which topology was split, deleted and created. For more information regarding these structures, please refer to the PK documentation for the PK_TOPOL_track_r_t structure. Returned Status and Error Information If this function returns a value of PK_ERROR_no_errors, the result of the "replace surface" operation will be indicated by the value of the status field within the results structure. There are two values for the status field which can indicate a successful operation : o PK_local_status_ok_c : Indicates that the operation was successful and the modified body is valid. o PK_local_status_nocheck_c : Indicates that the operation was successful, but the check_fa_fa field in the option structure was set to PK_check_fa_fa_no_c. The remaining `PK_local_status_...' codes indicate some failure. The failure code is normally accompanied by an array of entities which indicate where the failure or problem occurs. For more information regarding these failure codes and the returned error entities, please refer to the PK documentation for the PK_FACE_replace_surfs_r_t structure.