Esempio n. 1
0
 /// <summary>
 /// Returns true if the ray intersects the OrientatedBoundingBox
 /// </summary>
 /// <param name="r">Ray to test in the OrientatedBoundingBox</param>
 /// <returns>True if the ray intersects the OrientatedBoundingBox</returns>
 public bool Intersects(Ray r)
 {
     return r.Intersects(this);
 }
Esempio n. 2
0
 /// <summary>
 /// Checks for an intersection between a ray and an OrientatedBoundingBox
 /// </summary>
 /// <param name="b">BoundingBox to check</param>
 /// <returns>True if an intersection exists</returns>
 public bool Intersects(OrientatedBoundingBox b)
 {
     Matrix4 inverse = b.Matrix.Inverse();
     Ray ray = new Ray(this.Origin * inverse, this.Direction * inverse);
     return ray.Intersects(new AxisAlignedBoundingBox(b.Min, b.Max));
 }
Esempio n. 3
0
 public override bool Intersect(Ray ray)
 {
     return(false);
 }