Ejemplo n.º 1
0
// Dist calculates the signed distance of q to the plane p.
//
// Implemented as described in:
//  Real-Time Collision Detection, 5.1.1 "Closest Point on Plane to Point".
func (p Plane3) Dist(q math.Vec3) float64 {
	return q.Dot(p.Normal) - p.Pos
}