示例#1
0
 void intersectionT()
 {
     T = operations.pointTIntersection(p4d[0], p4d[1], p4d[2], p4d[3], p4d[4], eps, ref lblFlatXYZ, ref lblSectionXYZ);
     if (T == null)
     {
         sectionTpoints = operations.pointsTIntersection(p4d[0], p4d[1], p4d[2], p4d[3], p4d[4], eps);
     }
 }
示例#2
0
        public bool Equals(Section4D Another)
        {
            if (Another.End.X != this.End.X || Another.End.Y != this.End.Y)
            {
                return(false);
            }

            if (Another.Start.X != this.Start.X || Another.Start.Y != this.Start.Y)
            {
                return(false);
            }

            return(true);
        }
        public void VisibleMN(Point4D M, Point4D N, Point4D A, Point4D B, Point4D C, Point4D L, Point4D T, double eps, ref bool isVisMN, ref bool isVisM, ref bool isVisN, ref bool isNoVis)
        {
            isVisMN = false; isVisM = false; isVisN = false; isNoVis = false;
            Section4D VisibleSection = sectionVisibleLine(M, N, A, B, C, L, T, eps);
            Section4D compare1       = new Section4D(M, N);
            Section4D compare2       = new Section4D(M, T);
            Section4D compare3       = new Section4D(T, N);

            if (VisibleSection == null)
            {
                return;
            }
            if (!compare1.CheckNull())
            {
                if (VisibleSection.Equals(compare1))
                {
                    isVisMN = true;
                    return;
                }
            }

            if (!compare2.CheckNull())
            {
                if (VisibleSection.Equals(compare2))
                {
                    isVisM = true;
                    return;
                }
            }

            if (!compare3.CheckNull())
            {
                if (VisibleSection.Equals(compare3))
                {
                    isVisN = true;
                    return;
                }
            }
            isNoVis = true;
        }
示例#4
0
        public Axonomertry(Point4D[] p4d, Point4D p4dT, Section4D section4d, int lengthAxis, int indent, double eps, bool changeL)
        {
            red        = new Pen(Color.Red);
            green      = new Pen(Color.Green);
            blue       = new Pen(Color.Blue);
            black      = new Pen(Color.Black);
            aqua       = new Pen(Color.Aqua, 2);
            darkOrange = new Pen(Color.DarkOrange, 2);

            this.changeL = changeL;

            this.p4d       = p4d;
            p4dTrans       = new Point4D[p4d.Length];
            p2d            = new Point2D[p4d.Length];
            this.p4dT      = p4dT;
            this.section4d = section4d;
            sectionTrans   = new Section4D();
            section2d      = new Section2D();


            transformMatrix = new MatrixTransform();
            operations      = new Operations3D();
            Rz = new Matrix(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
            Rx = new Matrix(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
            Mx = new Matrix(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
            Pz = new Matrix(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
            T  = new Matrix(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);

            Ao = new Matrix(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
            Cz = new Matrix(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
            Ac = new Matrix(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);

            this.Lx         = p4d[5].X;
            this.Ly         = p4d[5].Y;
            this.Lz         = p4d[5].Z;
            this.eps        = eps;
            this.lengthAxis = lengthAxis;
            this.indent     = indent;
        }