Struct rtow::hitable::HitPoint [] [src]

pub struct HitPoint {
    pub t: f64,
    pub p: Point3<f64>,
    pub normal: Vector3<f64>,
    pub material: Material,
}

The point of contact between a ray and a material.

Fields

the distance along the ray where the contact happens; more specifically, it satisfies the equation ray.origin + t * ray.direction() = p.

the actual 3D contact point.

the normal vector on the material surface in point p.

describes material properties; useful for determining what happens to the ray after contact (is it absorbed/reflected/refracted?).

Trait Implementations

Auto Trait Implementations

impl Send for HitPoint

impl Sync for HitPoint