|
利用NXOpen方式获取当前工作部件里面工作坐标系的矩阵值的方法。0 N' k( i2 p) D' c
+ i, F: W# t( t
- theSession->ListingWindow()->Open();% p3 P- D5 L5 d, z1 C! |
- NXOpen::Matrix3x3 wsmtx = workPart->WCS()->CoordinateSystem()->Orientation()->Element();( C2 r1 Y8 n3 K+ M
- std::ostringstream tempstring;
" k$ P, O% {/ t( f p+ Z - tempstring <<wsmtx.Xx<<","<<wsmtx.Xy<<","<<wsmtx.Xz<<"\n": |5 o% ^2 h: I' u
- <<wsmtx.Yx<<","<<wsmtx.Yy<<","<<wsmtx.Yz<<"\n"
7 S: W6 l4 ~% M4 u+ G - <<wsmtx.Zx<<","<<wsmtx.Zy<<","<<wsmtx.Zz<<"\n";
, Q- [3 ^4 ]( x - std::string covervalue = tempstring.str();, Z5 s) Y8 z9 ?% u8 j
- theSession->ListingWindow()->WriteFullline( covervalue );
复制代码
+ C3 x1 r3 C- G8 ?; C6 T! U9 T, ]4 h4 |4 Y: x% n c
; Y" g( ?/ u: H( I* [, L, [
|
|