NX二次开发 UFUN偏置曲线 UF_CURVE_create_offset_curve
本程序由里海提供
//NX二次开发 UFUN偏置曲线 UF_CURVE_create_offset_curve
#include "me.hpp"
#include <stdio.h>
#include <string.h>
#include <stdarg.h>
#include <uf.h>
#include <uf_ui.h>
#include <uf_curve.h>
#include <uf_obj.h>
#include <uf_modl_types.h>
#include <uf_modl.h>
#include <uf_vec.h>
static int MaskForCurves(UF_UI_selection_p_t select, void* type)
{
UF_UI_mask_t mask[4] = { { UF_line_type, 0, 0 },
{ UF_circle_type, 0, 0 },
{ UF_conic_type, 0, 0 },
{ UF_spline_type, 0, 0 } };
if (!UF_CALL(UF_UI_set_sel_mask(select,UF_UI_SEL_MASK_CLEAR_AND_ENABLE_SPECIFIC, 4, mask)))
return (UF_UI_SEL_SUCCESS);
else
return (UF_UI_SEL_FAILURE);
}
extern tag_t SelectCurve(char* prompt)
{
int resp;
double cp[3];
tag_t object, view;
UF_CALL(UF_UI_select_with_single_