From a2b5452339365f85a8728963893eefb43bd8bdcc Mon Sep 17 00:00:00 2001 From: Morozov-5F Date: Mon, 29 Nov 2021 01:19:20 +0300 Subject: [PATCH] [#4] Use proper transform for the cube in the metal showcase scene. --- scenes/rt_scenes.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/scenes/rt_scenes.c b/scenes/rt_scenes.c index 8a199b9..3217ba2 100644 --- a/scenes/rt_scenes.c +++ b/scenes/rt_scenes.c @@ -332,8 +332,9 @@ rt_hittable_list_t *rt_scene_metal_test(void) rt_hittable_list_add(objects, rt_sphere_new(point3(2, 2, 0), 1, rt_mt_metal_new(colour(0.8, 0.8, 0.9), 1.0))); rt_hittable_t *box_instance = - rt_instance_new(rt_box_new(point3(-1, 0, 10), point3(1, 2, 12), rt_mt_metal_new(colour(0.8, 0.8, 0.9), 0.0))); - rt_instance_rotate_y(box_instance, 10); + rt_instance_new(rt_box_new(point3(-1, -1, -1), point3(1, 1, 1), rt_mt_metal_new(colour(0.8, 0.8, 0.9), 0.0))); + rt_instance_rotate_y(box_instance, 45); + rt_instance_translate(box_instance, vec3(2, 1, 11)); rt_hittable_list_add(objects, box_instance); return objects;