|
- //计算平面矩形点
- void BuildRect( const AcGePoint3d& pt, double angle, double width, double height, AcGePoint3dArray& pts )
- {
- AcGeVector3d v1( AcGeVector3d::kXAxis ), v2( AcGeVector3d::kXAxis );
- v1.rotateBy( angle, AcGeVector3d::kZAxis );
- v2.rotateBy( angle + CMGeometry::PI() / 2, AcGeVector3d::kZAxis );
- pts.append( CaclPt( pt, v1, width, v2, height ) );
- v1.rotateBy( CMGeometry::PI(), AcGeVector3d::kZAxis );
- pts.append( CaclPt( pt, v1, width, v2, height ) );
- v2.rotateBy( CMGeometry::PI(), AcGeVector3d::kZAxis );
- pts.append( CaclPt( pt, v1, width, v2, height ) );
- v1.rotateBy( CMGeometry::PI(), AcGeVector3d::kZAxis );
- pts.append( CaclPt( pt, v1, width, v2, height ) );
- }
复制代码 |
|