Basic driver for the ray tracer

This commit is contained in:
Eryn Wells 2013-09-07 16:10:42 -07:00
parent 9d6c293cad
commit dc558c016b

View file

@ -5,10 +5,32 @@
* Eryn Wells <eryn@erynwells.me>
*/
#include <stdio.h>
#include <png.h>
#include "scene.h"
#include "writer_png.h"
char *OUT_FILE = "charles_out.png";
int
main(int argc,
const char *argv[])
{
FILE *out_file = fopen(OUT_FILE, "wb");
if (!out_file) {
return -1;
}
Scene *scene = scene_init();
scene_render(scene);
write_scene_png(scene, out_file);
scene_destroy(scene);
fclose(out_file);
return 0;
}