Esempio n. 1
0
        public static Rhino.Geometry.Transform ToRhino(this NXOpen.Matrix4x4 value)
        {
            var rhino = RawDecoder.ToRhinoTransform(value);

            UnitConverter.Scale(ref rhino, UnitConverter.NXToRhinoUnitsRatio);
            return(rhino);
        }
Esempio n. 2
0
        public static Rhino.Geometry.Transform ToRhinoTransform(NXOpen.Matrix4x4 transform)
        {
            var value = new Rhino.Geometry.Transform
            {
                M00 = transform.Rxx,
                M10 = transform.Rxy,
                M20 = transform.Rxz,
                M30 = 0.0,

                M01 = transform.Ryx,
                M11 = transform.Ryy,
                M21 = transform.Ryz,
                M31 = 0.0,

                M02 = transform.Rzx,
                M12 = transform.Rzy,
                M22 = transform.Rzz,
                M32 = 0.0,

                M03 = transform.Sx,
                M13 = transform.Sy,
                M23 = transform.Sz,
                M33 = 1.0
            };

            return(value);
        }