public Plane GetPlane3D(PlaneDescriptor planeDesc)
        {
            Vector3 firstAxis  = GetAxis3D(planeDesc.FirstAxisDescriptor);
            Vector3 secondAxis = GetAxis3D(planeDesc.SecondAxisDescriptor);

            return(new Plane(Vector3.Normalize(Vector3.Cross(firstAxis, secondAxis)), Position3D));
        }
Example #2
0
        public static Plane GetLocalPlane(this Transform transform, PlaneDescriptor planeDesc)
        {
            Vector3 firstAxis  = transform.GetLocalAxis(planeDesc.FirstAxisDescriptor);
            Vector3 secondAxis = transform.GetLocalAxis(planeDesc.SecondAxisDescriptor);

            return(new Plane(Vector3.Normalize(Vector3.Cross(firstAxis, secondAxis)), transform.position));
        }
        public Plane GetPlane3D(PlaneId planeId, PlaneQuadrantId planeQuadrantId)
        {
            PlaneDescriptor planeDesc  = new PlaneDescriptor(planeId, planeQuadrantId);
            Vector3         firstAxis  = GetAxis3D(planeDesc.FirstAxisDescriptor);
            Vector3         secondAxis = GetAxis3D(planeDesc.SecondAxisDescriptor);

            return(new Plane(Vector3.Normalize(Vector3.Cross(firstAxis, secondAxis)), Position3D));
        }