Switch to mutable rays (#13)

This commit is contained in:
Patrick Stevens
2023-01-07 11:24:23 +00:00
committed by GitHub
parent 2cf9dd0bdb
commit 075890919c
9 changed files with 379 additions and 325 deletions

View File

@@ -6,14 +6,14 @@ type ior
type LightRay =
{
Ray : Ray
Colour : Pixel
// We have chosen not to include refractance here, because that would mean
// we had to model the material at every point in space rather than just the
// ratio of refractance at the boundaries of objects. (For example, if we
// modelled a light ray leaving a glass sphere, we would have to know what
// material we were leaving *into*, which we can't easily know given the
// current structure of things.)
// We have chosen not to include refractance here, because that would mean
// we had to model the material at every point in space rather than just the
// ratio of refractance at the boundaries of objects. (For example, if we
// modelled a light ray leaving a glass sphere, we would have to know what
// material we were leaving *into*, which we can't easily know given the
// current structure of things.)
mutable Ray : Ray
mutable Colour : Pixel
}
type LightDestination =