diff options
Diffstat (limited to 'main.c')
-rw-r--r-- | main.c | 8 |
1 files changed, 3 insertions, 5 deletions
@@ -93,12 +93,10 @@ int main() for (int x = TESTW; x; x--) { // Random seed seed = x * y; - color_t *c = ray_trace(&cont->space, x, y, 2, &seed); + color_t c; + ray_trace(&cont->space, x, y, 2, &c, &seed); - if (c) { - pgm_write_pixel(stdout, c); - } - free(c); + pgm_write_pixel(stdout, &c); } |