Esempio n. 1
0
        // Token: 0x060003C6 RID: 966 RVA: 0x00010DF8 File Offset: 0x0000EFF8
        public static Vector3?IntersectionWith(this Ray3 ray, Triangle3 triangle)
        {
            IntersectionRay3Triangle3 intersectionRay3Triangle = new IntersectionRay3Triangle3(ray, triangle);

            if (intersectionRay3Triangle.Find() && intersectionRay3Triangle.IntersectionType != Intersection.Type.IT_EMPTY)
            {
                return(new Vector3?(ray.Origin + intersectionRay3Triangle.RayParameter * ray.Direction));
            }
            return(null);
        }
Esempio n. 2
0
        // Token: 0x060003C5 RID: 965 RVA: 0x00010DD8 File Offset: 0x0000EFD8
        public static bool Intersects(this Ray3 ray, Triangle3 triangle)
        {
            IntersectionRay3Triangle3 intersectionRay3Triangle = new IntersectionRay3Triangle3(ray, triangle);

            return(intersectionRay3Triangle.Find());
        }