It's a long time . after I reviewed this post. paste the correct codes about SmarkLook ultimately.
DVec3d Dvec_Line = DVec3d::FromStartEndNormalize(linePts[0], linePts[1]);
DVec3d dpt = DVec3d::From(1.0, 0.0, 0.0);
RotMatrix RtMatrix;
mdlRMatrix_fromVectorToVector(&RtMatrix, &dpt, &Dvec_Line);
mdlRMatrix_transpose(&RtMatrix, &RtMatrix);
mdlState_setAccudrawContext(
ACCUDRAW_SetOrigin | ACCUDRAW_SetRMatrix | ACCUDRAW_Lock_X,
&pt,
NULL,
NULL,
NULL,
&RtMatrix
);
DVec3d Dvec_Line = DVec3d::FromStartEndNormalize(linePts[0], linePts[1]);
DVec3d dpt = DVec3d::From(1.0, 0.0, 0.0);
RotMatrix RtMatrix;
mdlRMatrix_fromVectorToVector(&RtMatrix, &dpt, &Dvec_Line);
mdlRMatrix_transpose(&RtMatrix, &RtMatrix);
mdlState_setAccudrawContext(
ACCUDRAW_SetOrigin | ACCUDRAW_SetRMatrix | ACCUDRAW_Lock_X,
&pt,
NULL,
NULL,
NULL,
&RtMatrix
);