|
请使用QQ关联注册PLM之家,学习更多关于内容,更多精彩原创视频供你学习!
您需要 登录 才可以下载或查看,没有账号?注册
x
/*********************************************************// Z/ z7 O( s1 v2 x% [
#include <stdio.h>
, X' M/ s7 O/ q0 x- U' B#include <stdlib.h>9 S2 A# A! G- |, G& z8 K6 S- h
#include <uf.h>
: t! f$ A: j' @: r7 U/ A#include <uf_attr.h>5 _4 v0 I" Z* |7 y0 J+ ]7 p/ w1 q- k3 q
#include <uf_cfi.h>0 P/ ~; B) [* b" h+ b
#include <uf_curve.h>0 Y# G* a# G; s1 Z5 S# X1 \6 D& b
#include <uf_ui.h>% w/ e0 u/ I1 ?, G3 J8 |
#include <uf_modl.h>
9 G4 B7 C5 Q# [$ u3 U$ U5 y( ^
/************* unload alloc mem *************************/
7 L' z. U0 ~4 n6 @# l/* UF_UNLOAD_SEL_DIALOG _UG_TERMINATE _IMMEDIATELY */
9 H! W5 A! k: p' \
8 o% w, C, _ c9 [% N+ e( nextern void ufusr( char *param, int *reTCod, int param_len )
% b. V' i1 \8 v R& E{
T' I5 h: [. Q. D2 _5 s- o UF_initialize();! I1 Q3 ?3 l, W# i& K0 ]
8 P N" @$ w# @( A* w( W" u% ?
5 q' h3 R- W& ]) t T) y( W double coner[3]={0,0,0};0 w. ?( Q" N6 \ h5 I7 B4 Y: j
char *edge[3] = {"10","50","20"};
7 |# g/ }4 D. F* m% |. r" `) N tag_t blk_tag;- C4 R, k7 P5 J3 i9 G% d
UF_MODL_create_block1(UF_NULLSIGN,coner,edge,&blk_tag);
: `0 [7 ~$ I; r9 Z0 p
, ^( J( ?' h+ d. g9 r7 R% f& u! H# l. a. \0 }, O
UF_MODL_ask_feat_body(blk_tag,&blk_tag);- |" \ }% t; b9 Y X( x% t
uf_list_p_t end_list;- t5 I" s$ C& Y1 e' m
UF_MODL_create_list(&end_list);
2 I# q, p$ r9 w1 R4 O UF_MODL_ask_body_edges(blk_tag,&end_list);
6 X5 L2 l, `) O* }' d: J5 j int num;
5 D% \/ R8 w J: i' v UF_MODL_ask_list_count(end_list,&num);
% ^+ }3 \8 o: a
" j) G/ n& p+ @+ T char *radius ="2";
3 c) k3 ?0 M4 D9 s: [5 H q int smooth_overflow = 0;
2 B; t/ b6 o3 v, p9 a; o int cliff_overflow = 0;" }# H% K* c( m4 |3 L6 h
int notch_overflow = 0;
Y, Q6 m% _1 Z7 H double vrb_tool = 0;
$ J0 W J- X/ O! m tag_t feature_obj_id ;. P; c- P9 i$ {# @
uf_list_p_t end_list2;
~& I: ^/ y" ]8 G, _4 C6 o+ c UF_MODL_create_list(&end_list2);
9 t, a; J3 z. f- W: h for (int i = 0; i < num ; i++)' U# h$ M! t, ?, t8 _
{
/ \ e" w+ D% i9 D. s9 @ tag_t tt,curve1;8 g* F+ k* t: t! r9 m' x
UF_MODL_ask_list_item(end_list,i,&tt);
0 x" R. H( W8 \. {: L, C4 q9 @7 | UF_MODL_create_curve_from_edge(tt,&curve1); //抽取曲线
( K; n) }7 L3 j# G4 Y; `* ~" q double point1 [ 3 ] ;
5 M; x _! a1 G3 s- ]. ~0 t double point2 [ 3 ] ;
$ Y& s7 c1 f; h& G7 Y! v& d int vertex_count;
}3 f8 ], S' a8 m4 D+ Z: C UF_MODL_ask_edge_verts(tt,point1,point2,&vertex_count);3 K. X; {) ?4 B/ f! ?' S C
if ((point1[0]==point2[0])&(point1[1]==point2[1])) h' i& N5 F' j. X
{
, l4 w8 S. w( Z7 l: }" Z2 w6 s UF_MODL_put_list_item(end_list2,tt);
/ n9 c8 k* [' d% k4 @, F3 y: \& m6 l }0 w. ]; ~, I7 c& v! t
}. Q* L, M1 K+ l
UF_MODL_create_blend(radius,end_list2,smooth_overflow,cliff_overflow,notch_overflow,vrb_tool,&feature_obj_id);* |( e% E( B8 g" ]3 I
UF_MODL_delete_list(&end_list);
! C: W; m. d* r; l( D/ K( w
& u6 A4 N7 W) _4 v UF_terminate();
4 A& T$ X+ i+ A% V& C, e$ y; Z* S return; N2 `# ~# y3 h/ h
}
9 o4 Q2 v5 y9 a; e9 ?* ~3 t6 B
& a# c" A6 q7 J* e! @extern int ufusr_ask_unload()' a2 Z. P, m4 m
{8 W9 `* F9 z3 x; k) m/ d0 A
return UF_UNLOAD_IMMEDIATELY;
3 D0 L. S7 j8 C}, w7 E! x' o( a: G6 e$ Z9 ]
' ~: R8 K$ L) e) m, _% A |
-
评分
-
查看全部评分
|