diff options
| author | Martin Lehoux <martin@lehoux.net> | 2020-04-05 22:46:01 -0700 |
|---|---|---|
| committer | Martin Lehoux <martin@lehoux.net> | 2020-04-05 22:46:01 -0700 |
| commit | e93eee4bb96bd2d81e422dc9d453da6138fd6ba2 (patch) | |
| tree | 0ef600be27a5bcde32d04283563c7b9fb8dd50d5 /ray.go | |
| parent | 8730659596dbfdb9625c0fc413625b261f7d6d70 (diff) | |
misc - Doc
Diffstat (limited to 'ray.go')
| -rw-r--r-- | ray.go | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -1,9 +1,11 @@ package main +// Ray contains a ray data type Ray struct { origin, direction Vec3D } +// PointAt computes ray position at a time func (ray Ray) PointAt(time float64) Vec3D { return AddVec3D(ray.origin, ScalarProduct(time, ray.direction)) } |
