Community Tip - Learn all about the Community Ranking System, a fun gamification element of the PTC Community. X
Hello,
I have a sketching plane and i want Its local coordinate system needed for creating section where i need to pass tranf[4][3] in ProXsceOffsetCreate(Prosolid,ProName,double tranf[4][3],Pro2dLinedef*,ProXsecOffsetSide,int flip,ProXsecExcludeModels,ProAsmpath,ProXsec*).
If any one have solution of it please help.
get a component transformation matrix
get the parent datum plane or planar surface's ProGeomitem
get geomitem data with ProGeomitemdataGet(...)
get plane.e1, plane.e2, plane.e3 and plane.origin
transform e1, e2, e3 vectors and origin to assembly coordinates. normalize e1,e2,e3 - transformation might apply inch/metric scaling factor.
build transformation matrix from transformed vectors and origin with ProMatrixInit(...)
copy three elements of each four rows of the resulting matrix into 12-member array of doubles: d[0][0] = m[0][0] ... d[0][2] = m[0][2] and so on... This just gets rid of 0,0,0,1 fourth column of the transformation matrix.
HIH