diff options
author | Vito Caputo <vcaputo@pengaru.com> | 2017-06-02 11:00:36 -0700 |
---|---|---|
committer | Vito Caputo <vcaputo@pengaru.com> | 2017-06-02 11:11:16 -0700 |
commit | cbc6c0eaf45a7ede48465d1f6d6f7e24c14bd9ce (patch) | |
tree | 4eeab222cec158eac34cc47505177d9bcf9443af /src/modules/ray/ray.c | |
parent | 84a473d0369c8d676a5a42dcbd11039360668e40 (diff) |
ray: plumb depth and camera to objects
To enable prepare to precompute aspects of primary rays which all have a
common origin at the camera, bring the camera to ray_object*_prepare() and
bring the depth to ray_object*_intersects_ray() for primary ray detection.
This is only scaffolding, functionally unchanged.
Diffstat (limited to 'src/modules/ray/ray.c')
-rw-r--r-- | src/modules/ray/ray.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/modules/ray/ray.c b/src/modules/ray/ray.c index 1143db1..b80f384 100644 --- a/src/modules/ray/ray.c +++ b/src/modules/ray/ray.c @@ -146,7 +146,7 @@ static void ray_prepare_frame(void *context, unsigned n_cpus, fb_fragment_t *fra /* tilt camera pitch in time with up and down movements, phase shifted appreciably */ camera.orientation.pitch = sinf((M_PI * 1.5f) + r * 1.3f) * .6f + -.35f; #endif - ray_scene_prepare(&scene); + ray_scene_prepare(&scene, &camera); } |