예제 #1
0
 public void setRightPlane(LVector3 pivot, LVector3 rightEdgeVertex)
 {
     rightPlane.set(pivot, pivot.Add(LVector3.up), rightEdgeVertex); // 高度
     rightPlane.normal = -rightPlane.normal;                         // 平面方向取反
     rightPlane.d      = -rightPlane.d;
     rightPortal       = (rightEdgeVertex);
 }
예제 #2
0
 public Triangle(LVector3 a, LVector3 b, LVector3 c, int index, params int[] vectorIndex)
 {
     this.a           = a;
     this.b           = b;
     this.c           = c;
     this.y           = (a.y + b.y + c.y) / 3;
     this.index       = index;
     this.center      = a.Add(b).Add(c).scl(1 / 3.ToLFloat());
     this.connections = new List <Connection <Triangle> >();
     this.vectorIndex = vectorIndex;
 }
예제 #3
0
        public LVector3 pivot       = new LVector3(); // 漏斗点,路径的起点或拐点

        public void setLeftPlane(LVector3 pivot, LVector3 leftEdgeVertex)
        {
            leftPlane.set(pivot, pivot.Add(LVector3.up), leftEdgeVertex);
            leftPortal = leftEdgeVertex;
        }