ccdemos/realtime.cc
branchpyrit
changeset 40 929aad02c5f2
parent 39 7079dcc3bd74
child 72 7c3f38dff082
--- a/ccdemos/realtime.cc	Fri Dec 14 16:51:22 2007 +0100
+++ b/ccdemos/realtime.cc	Mon Dec 17 22:03:50 2007 +0100
@@ -1,9 +1,11 @@
+#include <stdlib.h>
+
 #include "raytracer.h"
 #include "octree.h"
 
 #include "common_sdl.h"
 
-int main()
+int main(int argc, char **argv)
 {
 	Raytracer rt;
 	Octree top;
@@ -23,7 +25,7 @@
 	Material mat_sph(Colour(1.0, 1.0, 1.0));
 	for (int y=0; y<10; y++)
 		for (int x=0; x<10; x++)
-			rt.addshape(new Sphere(Vector3(x*2-10, (Float)random()/RAND_MAX*5.0, y*2-10), 0.45, &mat_sph));
+			rt.addshape(new Sphere(Vector3(x*2-10, (Float)rand()/RAND_MAX*5.0, y*2-10), 0.45, &mat_sph));
 
 	rt.setCamera(&cam);
 	cam.setEye(Vector3(0,0,10));