天气与日历 切换到窄版

 找回密码
 立即注册
中国膜结构网
十大进口膜材评选 十大国产膜材评选 十大膜结构设计评选 十大膜结构公司评选
查看: 7|回复: 0

从平面到世界所需的转换

[复制链接]
  • TA的每日心情
    开心
    昨天 15:23
  • 签到天数: 69 天

    [LV.6]常住居民II

    410

    主题

    167

    回帖

    2704

    积分

    管理员

    积分
    2704
    发表于 2024-6-22 09:46:18 | 显示全部楼层 |阅读模式
    AcGeMatrix3d::setToPlaneToWorld确定从平面到世界所需的转换。下面是一个示例代码段,它使用AcGeMatrix3d::alignCoordSys来确定相同的矩阵。我希望这有助于您理解AcGeMatrix3d::setToPlaneToWorld的功能。

    AcGePlane testPlane = AcGePlane::kZXPlane;

    // Plane Origin, X axis, Y axis and Z axis
    AcGePoint3d        fromOrigin;  
    AcGeVector3d fromXAxis;
    AcGeVector3d fromYAxis;
    testPlane.getCoordSystem(fromOrigin, fromXAxis, fromYAxis);
    AcGeVector3d fromZAxis = testPlane.normal();

    AcGeMatrix3d mat1 = AcGeMatrix3d::kIdentity;
    mat1 = AcGeMatrix3d::alignCoordSys(        fromOrigin,
                                                                            fromXAxis,
                                                                            fromYAxis,
                                                                            fromZAxis,
                                                                            AcGePoint3d::kOrigin,
                                                                            AcGeVector3d::kXAxis,
                                                                            AcGeVector3d::kYAxis,
                                                                            AcGeVector3d::kZAxis
                                                                     );
    mat1 = mat1.inverse();

    // Verify the matrix
    AcGeMatrix3d mat2 = AcGeMatrix3d::kIdentity;
    mat2 = AcGeMatrix3d::planeToWorld( testPlane );

    if(mat1.isEqualTo(mat2))
            acutPrintf(ACRX_T("Results are the same !!"));
    else
            acutPrintf(ACRX_T("Results differ !!"));

     

     

     

     

    从平面到世界所需的转换
    中国膜结构网打造全中国最好的膜结构综合平台 ,统一协调膜结构设计,膜结构施工,膜材采购,膜材定制,膜结构预算全方位服务。 中国空间膜结构协会合作单位。
    您需要登录后才可以回帖 登录 | 立即注册

    本版积分规则

    QQ|Archiver|手机版|中国膜结构网|中国膜结构协会|进口膜材|国产膜材|ETFE|PVDF|PTFE|设计|施工|安装|车棚|看台|污水池|

    GMT+8, 2024-7-1 05:33 , Processed in 0.055983 second(s), 22 queries .

    Powered by Discuz! X3.5

    © 2001-2024 Discuz! Team.

    快速回复 返回顶部 返回列表