iCAx开思工具箱

标题: UF_MODL_create_law_extension遇到问题 [打印本页]

作者: zhangruzhen    时间: 2008-7-4 09:24
标题: UF_MODL_create_law_extension遇到问题
请高手们帮我看看,我这样做为什么执行最后一句的时候出现“外部库出错”的错误,不能完成延伸。多多指教,谢谢了!
int law_method = 1;    char law_str1[] = "50";    char law_str2[] = "90";    UF_STRING_t spine_str;    UF_STRING_t law_cv_str;    UF_MODL_init_string_list(&spine_str);    UF_MODL_create_string_list(0,0,&spine_str);    UF_MODL_init_string_list(&law_cv_str);    UF_MODL_create_string_list(0,0,&law_cv_str);    //int base_direction = 1;    void *uf_law_parms1;    void *uf_law_parms2;    int x = UF_MODL_create_law(law_method,law_str1,NULL,spine_str,law_cv_str,        0, NULL,NULL,NULL_TAG,NULL,&uf_law_parms1);    int y = UF_MODL_create_law(law_method,law_str2,NULL,spine_str,law_cv_str,        0, NULL,NULL,NULL_TAG,NULL,&uf_law_parms2);    UF_STRING_t stringlist;    UF_MODL_init_string_list(&stringlist);    UF_MODL_create_string_list(1,1,&stringlist);    stringlist.num = 1;    stringlist.string[0] = 1;    stringlist.dir[0] = UF_MODL_CURVE_START_FROM_BEGIN;    stringlist.id[0] = edgetag;    UF_MODL_parm_t len_law,angle_law;    len_law.method_type=UF_MODL_PARM_CONSTANT;    angle_law.method_type=UF_MODL_PARM_CONSTANT;    strcpy(len_law.defined_by.constant.value,"50");    strcpy(angle_law.defined_by.constant.value,"90");         tag_t extension;    double tol;    UF_MODL_lawext_data_s law_extension_data;    law_extension_data.ref_type = UF_MODL_lawext_dirref_face;    law_extension_data.length_law_parms = &len_law;    law_extension_data.angle_law_parms = &angle_law;    law_extension_data.curve = &stringlist;    law_extension_data.n_faces = 1;    law_extension_data.face_ids = new tag_t[1];    law_extension_data.face_ids[0] = planetag;    //law_extension_data.smart_dir = NULL_TAG;    law_extension_data.spine = NULL;    law_extension_data.distance_tol = 1e-5;    UF_MODL_ask_angle_tolerance(&tol);    law_extension_data.angle_tol = tol;    //law_extension_data.merge = 0;    //law_extension_data.bisided = 0;    UF_MODL_create_law_extension(&law_extension_data,&extension);




欢迎光临 iCAx开思工具箱 (https://t.icax.org/) Powered by Discuz! X3.3