|
请使用QQ关联注册PLM之家,学习更多关于内容,更多精彩原创视频供你学习!
您需要 登录 才可以下载或查看,没有账号?注册
x
NX二次开发源码分享: 根据 datum plane 更新 datum 法相方向5 R& ?3 p8 _2 ~* I7 t3 W2 y
6 @7 Y6 S$ U, t. x( R这里用到了 ufun函数,通过对象获取特征,然后通过特征进行更新1 Y" ^: p6 T% x1 t( Z7 u# Q+ A9 P
! E3 O0 A8 s9 M; v5 y' W4 d
- |1 s- i+ S( h/ M" l) Qtag_t featureTag = NULL_TAG;! I- s# j) @! ?, K7 ]
UF_MODL_ask_object_feat(DpX->Tag(),&featureTag);! Y' G* v5 [$ w/ c6 ?7 A
NXOpen::Features::DatumPlaneFeature *datumPlaneFeature1(dynamic_cast<NXOpen::Features::DatumPlaneFeature *>(NXObjectManager::Get(featureTag)));) C. H( T3 u! F9 _
NXOpen::Features::DatumPlaneBuilder *datumPlaneBuilder1;8 T) i. M# J t6 V
datumPlaneBuilder1 = workPart->Features()->CreateDatumPlaneBuilder(datumPlaneFeature1);
* j; K& q6 S) u; a6 s8 M
( i8 s$ w' g/ k6 s0 U NXOpen::Plane *plane1;
0 ?5 s3 N! y- d+ G8 i* O; p" T/ i( o. ]
plane1 = datumPlaneBuilder1->GetPlane();2 Y6 i& u: O2 X7 R' h9 E: j
- D+ a+ B' W3 `8 Y, w/ F0 ^
//uc1601(datumPlaneFeature1->GetFeatureName().GetUTF8Text(),1);# K' C7 m0 V) J& f4 W- I
3 a/ B& f! Y; Z, O$ E
plane1->SetFlip(true);
% w7 S5 t1 S2 e; w9 U( _
2 e# w$ I! c8 T2 l plane1->Evaluate();
7 N* f3 n% J9 D1 y0 ~
: F- `, i" X8 W: R: M3 } NXOpen::Features::Feature *feature1;
# T6 P4 a; x% b7 O) e. w; d feature1 = datumPlaneBuilder1->CommitFeature();
. {: s' Q1 _/ ]+ H+ y4 H. i3 l datumPlaneBuilder1->Destroy();( V8 P3 e: T2 m( u: p1 U" r
* Z9 I( i/ O4 |! G
|
|