diff options
author | Julian T <julian@jtle.dk> | 2020-02-21 14:42:42 +0100 |
---|---|---|
committer | Julian T <julian@jtle.dk> | 2020-02-21 14:42:42 +0100 |
commit | 9b40029e42f994aeff59ecc44a6d3b8fba93071d (patch) | |
tree | c133f8f6190b445560c4d8438ba89d7caaa0a7cd /main.c | |
parent | 623fee395425ab33f14fb9cd8ffa790e362f59d7 (diff) |
Pretty realistic colors
Diffstat (limited to 'main.c')
-rw-r--r-- | main.c | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -19,6 +19,9 @@ int main() s.objects = NULL; s.lights = NULL; + material_t m; + vector_set(&m.color, 0, 1, 0); + vector_set(&s.view.position, 0, 15, 10); vector_set(&s.view.target, 0, 0, 0); s.view.width = TESTW; @@ -27,8 +30,8 @@ int main() viewpoint_init(&s.view); // Setup plane - add_sphere(&s, vector_set(NULL, 0, 0, 5), 5); - add_sphere(&s, vector_set(NULL, 10, 0, 5), 5); + add_sphere(&s, vector_set(NULL, 0, 0, 5), 5, &m); + //add_sphere(&s, vector_set(NULL, 10, 0, 5), 5); add_plane(&s, vector_set(NULL, 0, 0, 2), vector_set(NULL, 0, 0, 1)); add_light(&s, vector_set(NULL, 10, 0, 20), color_set(NULL, 255, 255, 255)); |