コード例 #1
0
        // Token: 0x060000E9 RID: 233 RVA: 0x000091B8 File Offset: 0x000073B8
        protected internal override void InitializeFromAssembly(AssemblyInstance assemblyInstance)
        {
            bool flag = assemblyInstance == null;

            if (!flag)
            {
                Wall                wall         = assemblyInstance.getMainElement() as Wall;
                ItGeMatrix3d        mat          = ItGeMatrix3d.rotation(-1.5707963267948966, ItGeVector3d.kXAxis, ItGePoint3d.kOrigin);
                ItGeMatrix3d        itGeMatrix3d = ItGeMatrix3d.translation(new ItGeVector3d(0.0, 0.0, wall.thickness()));
                Position            position     = Position.Undefined;
                RevitElement <Part> part         = assemblyInstance.getPart(null);
                bool                flag2        = part.isNotNull();
                if (flag2)
                {
                    position = part.getViewsidePosition();
                }
                ItGeMatrix3d mat2  = ItGeMatrix3d.kIdentity;
                bool         flag3 = position != Position.Right;
                if (flag3)
                {
                    ItGeBoundBlock3d localExtents = assemblyInstance.getLocalExtents();
                    ItGePoint3d      itGePoint3d  = localExtents.midPoint;
                    itGePoint3d = itGeMatrix3d * mat * itGePoint3d;
                    mat2        = ItGeMatrix3d.rotation(3.1415926535897931, ItGeVector3d.kYAxis, itGePoint3d);
                }
                base.MatAssemblyToPalette = mat2 * itGeMatrix3d * mat;
                base.InitializeFromAssembly(assemblyInstance);
            }
        }
コード例 #2
0
        // Token: 0x060000D6 RID: 214 RVA: 0x00008F20 File Offset: 0x00007120
        protected internal override void InitializeFromAssembly(AssemblyInstance assemblyInstance)
        {
            ItGeMatrix3d     itGeMatrix3d     = ItGeMatrix3d.rotation(-1.5707963267948966, ItGeVector3d.kZAxis, ItGePoint3d.kOrigin);
            ItGeBoundBlock3d itGeBoundBlock3d = assemblyInstance.getLocalExtents().transformBy(itGeMatrix3d);

            base.MatAssemblyToPalette = ItGeMatrix3d.translation(itGeBoundBlock3d.minPoint.asVector().negate()) * itGeMatrix3d;
            base.InitializeFromAssembly(assemblyInstance);
        }
コード例 #3
0
        // Token: 0x06000215 RID: 533 RVA: 0x0000E988 File Offset: 0x0000CB88
        private ItSegment GetStartSegment(ItBar xmlBar)
        {
            ItGeMatrix3d mat       = ItGeMatrix3d.rotation(xmlBar.RotZ * 3.1415926535897931 / 180.0, ItGeVector3d.kZAxis, ItGePoint3d.kOrigin);
            ItGeVector3d xAxis     = mat * ItGeVector3d.kXAxis;
            ItGeVector3d yAxis     = mat * ItGeVector3d.kYAxis;
            ItGeVector3d zAxis     = mat * ItGeVector3d.kZAxis;
            double       l         = 0.0;
            double       r         = 0.0;
            double       rotX      = 0.0;
            double       bendY     = 0.0;
            ItGeMatrix3d kIdentity = ItGeMatrix3d.kIdentity;

            kIdentity.setCoordSystem(ItGePoint3d.kOrigin, xAxis, yAxis, zAxis);
            return(new ItSegment(l, r, rotX, bendY, kIdentity, "normal"));
        }