mirror of
https://github.com/Smaug123/ray-tracing-fsharp
synced 2025-10-18 10:08:39 +00:00
Switch to mutable rays (#13)
This commit is contained in:
@@ -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 =
|
||||
|
Reference in New Issue
Block a user