PK_ERROR_code_t PK_BODY_fix_blends ( --- received arguments --- PK_BODY_t body, --- edge to have blends fixed const PK_BODY_fix_blends_o_t *options, --- options structure --- returned arguments --- int *const n_blends, --- number of blend faces PK_FACE_t **const blends, --- created blend faces PK_FACE_array_t **const faces, --- underlying faces int **const edges, --- edges that have been replaced PK_blend_fault_t *const fault, --- status PK_EDGE_t *const fault_edge, --- first edge for which blend --- can't be fixed --- (may be PK_ENTITY_null) PK_TOPOL_t *const fault_topol --- topology associated with --- fault (may be PK_ENTITY_null) ) This function changes any edges of the given body which have had blends set on them by the PK_EDGE_set_blend_ functions, into faces with the appropriate surface geometry. Specific Errors: PK_ERROR_cant_fix_blends can't fix blends in body PK_ERROR_general_body general body Any edges of the body which have blend attributes are changed into full faces with the appropriate blending surface geometry. checking options The local_check flag and the checks data structure are used to control the amount of checking during the blending operation: If local_check is set to PK_LOGICAL_true, then checks will be ignored, and the level of local checking will be: No surface self-intersection checks will be performed Face checks will be performed Face-face inconsistency checks will be performed. If local_check is set to PK_LOGICAL_false, then the amount of local checking will be determined by checks. PK_BODY_fix_blends returns the number of created blend faces, and three arrays: blends will contain n_blends faces, which are the created blend faces. faces will contain the underlying faces associated with the blends. The underlying faces of a blend are the faces whose geometry determines the blend surface geometry. Some of the face tags may be null. This occurs if there is no face in the final body with the appropriate surface geometry, which can be the case if a face has been entirely blended away, or for the cliff side of a cliffedge blend. edges will contain n_blends integers. These integers are the (dead) tags of the edges which were blended to produce this set of blends. The same value may occur several times in this list if, for example, a blend has overflowed, since all the corresponding faces in blends were caused by the same blend attribute. The user can set the option vx_twin to request that the integer in edges be the (dead) tag of the appropriate vertex instead, for those blend faces which are generated from vertices (default is PK_LOGICAL_false). The option transfer is used to select whether any topology in the region which has been completely overlapped by the blend will be transferred into the blend faces or whether it will be deleted. If the attempt to fix the blend fails due to an error which would be detected by PK_EDGE_check_blends, the edge associated with the error will be returned in fault_edge and fault and fault_topol are the same as would be returned if PK_EDGE_check_blends was called with fault_edge. These can be used to locate the reason for failure to fix the blend. Note that only the first error will be returned. If no errors are found fault will be PK_blend_fault_no_fault_c and fault_edge and fault_topol will be PK_ENTITY_null. If the local_check flag is set to PK_logical_false and a self-intersecting surface or a face-face inconsistency is detected during a local check specified by the application, then fault will be set accordingly, fault_edge will be set to PK_ENTITY_null and fault_topol will be set to one of the invalid faces. The blend will have been attached. The option preserve_notch only has an effect when a sheet body is being blended. If it is set to PK_LOGICAL_false, PK_BODY_fix_blends will make a simple curve within the blend surface to bridge a laminar notch. If this option is set to PK_LOGICAL_true, the shape of the notch is projected normally onto the blend surface to bridge the notch gap. If a solid body is being blended this option has no effect and is ignored. The option update en/dis-ables some changes to the blending algorithms which might cause differences in model updates between versions. It currently has two values: PK_blend_edge_update_0_c for updating v9.1 to v12.1models PK_blend_edge_update_1_c for updating v13.0 models Note that blends created with the property draw_fix set to PK_LOGICAL_false will not be fixed. This function is not supported for general bodies.