6.837 Intro to Computer Graphics, Fall 2003
Assignment 4: Grid Acceleration

Assignment Description (.pdf)

New & Updated files:

Input Files


Sample Results
(your statistics will probably be a little different --- that's ok)

raytracer -input scene1_cube_mesh.txt -output out1_noshadows.tga -size 300 300 -no_shadows

********************************************
RAY TRACING STATISTICS
  total time                 0:00:03
  num pixels                 90000 (300x300)
  scene bounds               (-1.00 -1.00 -1.00) -> (1.00 1.00 1.00)
  num grid cells             0 (0x0x0)
  num non-shadow rays        90000
  num shadow rays            0
  total intersections        1080000
  total cells traversed      0
  rays per second            30000.0
  rays per pixel             1.0
  intersections per ray      12.0
  cells traversed per ray    0.0
********************************************

raytracer -input scene1_cube_mesh.txt -output out1.tga -size 300 300

********************************************
RAY TRACING STATISTICS
  total time                 0:00:03
  num pixels                 90000 (300x300)
  scene bounds               (-1.00 -1.00 -1.00) -> (1.00 1.00 1.00)
  num grid cells             0 (0x0x0)
  num non-shadow rays        90000
  num shadow rays            31656
  total intersections        1459872
  total cells traversed      0
  rays per second            40552.0
  rays per pixel             1.4
  intersections per ray      12.0
  cells traversed per ray    0.0
********************************************


raytracer -input scene2_bunny_mesh_200.txt -output out2_noshadows.tga -size 300 300 -no_shadows

********************************************
RAY TRACING STATISTICS
  total time                 0:00:45
  num pixels                 90000 (300x300)
  scene bounds               (-0.19 0.07 -0.11) -> (0.12 0.37 0.12)
  num grid cells             0 (0x0x0)
  num non-shadow rays        90000
  num shadow rays            0
  total intersections        18000000
  total cells traversed      0
  rays per second            2000.0
  rays per pixel             1.0
  intersections per ray      200.0
  cells traversed per ray    0.0
********************************************

raytracer -input scene2_bunny_mesh_200.txt -output out2.tga -size 300 300

********************************************
RAY TRACING STATISTICS
  total time                 0:01:01
  num pixels                 90000 (300x300)
  scene bounds               (-0.19 0.07 -0.11) -> (0.12 0.37 0.12)
  num grid cells             0 (0x0x0)
  num non-shadow rays        90000
  num shadow rays            61594
  total intersections        30318800
  total cells traversed      0
  rays per second            2485.1
  rays per pixel             1.7
  intersections per ray      200.0
  cells traversed per ray    0.0
********************************************


raytracer -input scene3_rasterize_sphere_5x5x5.txt -output out3_noshadows.tga -size 300 300 -no_shadows

********************************************
RAY TRACING STATISTICS
  total time                 0:00:01
  num pixels                 90000 (300x300)
  scene bounds               (-1.50 -1.50 -1.50) -> (1.50 1.50 1.50)
  num grid cells             0 (0x0x0)
  num non-shadow rays        90000
  num shadow rays            0
  total intersections        90000
  total cells traversed      108770
  rays per second            90000.0
  rays per pixel             1.0
  intersections per ray      1.0
  cells traversed per ray    1.2
********************************************

raytracer -input scene3_rasterize_sphere_5x5x5.txt -output out3.tga -size 300 300

********************************************
RAY TRACING STATISTICS
  total time                 0:00:01
  num pixels                 90000 (300x300)
  scene bounds               (-1.50 -1.50 -1.50) -> (1.50 1.50 1.50)
  num grid cells             0 (0x0x0)
  num non-shadow rays        90000
  num shadow rays            85590
  total intersections        175590
  total cells traversed      209780
  rays per second            175590.0
  rays per pixel             2.0
  intersections per ray      1.0
  cells traversed per ray    1.2
********************************************


raytracer -input scene4_rasterize_sphere_5x5x5.txt -output out4_noshadows.tga -size 300 300 -no_shadows

********************************************
RAY TRACING STATISTICS
  total time                 0:00:01
  num pixels                 90000 (300x300)
  scene bounds               (-1.50 -1.50 -1.50) -> (1.50 1.50 1.50)
  num grid cells             0 (0x0x0)
  num non-shadow rays        90000
  num shadow rays            0
  total intersections        90000
  total cells traversed      139282
  rays per second            90000.0
  rays per pixel             1.0
  intersections per ray      1.0
  cells traversed per ray    1.5
********************************************

raytracer -input scene4_rasterize_sphere_5x5x5.txt -output out4.tga -size 300 300

********************************************
RAY TRACING STATISTICS
  total time                 0:00:01
  num pixels                 90000 (300x300)
  scene bounds               (-1.50 -1.50 -1.50) -> (1.50 1.50 1.50)
  num grid cells             0 (0x0x0)
  num non-shadow rays        90000
  num shadow rays            114952
  total intersections        204952
  total cells traversed      239560
  rays per second            204952.0
  rays per pixel             2.3
  intersections per ray      1.0
  cells traversed per ray    1.2
********************************************


raytracer -input scene5_rasterize_sphere_20x20x20.txt -output out5_noshadows.tga -size 300 300 -no_shadows

********************************************
RAY TRACING STATISTICS
  total time                 0:00:01
  num pixels                 90000 (300x300)
  scene bounds               (-1.50 -1.50 -1.50) -> (1.50 1.50 1.50)
  num grid cells             0 (0x0x0)
  num non-shadow rays        90000
  num shadow rays            0
  total intersections        90000
  total cells traversed      594191
  rays per second            90000.0
  rays per pixel             1.0
  intersections per ray      1.0
  cells traversed per ray    6.6
********************************************
[

raytracer -input scene5_rasterize_sphere_20x20x20.txt -output out5.tga -size 300 300

********************************************
RAY TRACING STATISTICS
  total time                 0:00:01
  num pixels                 90000 (300x300)
  scene bounds               (-1.50 -1.50 -1.50) -> (1.50 1.50 1.50)
  num grid cells             0 (0x0x0)
  num non-shadow rays        90000
  num shadow rays            87060
  total intersections        177060
  total cells traversed      929248
  rays per second            177060.0
  rays per pixel             2.0
  intersections per ray      1.0
  cells traversed per ray    5.2
********************************************


raytracer -input scene2_bunny_mesh_200.txt -output out_grid_200_10x10x10.tga -size 300 300 -grid 10 10 10 -visualize_grid -no_shadows

raytracer -input scene2_bunny_mesh_200.txt -output out_grid_200_10x10x10_count.tga -size 300 300 -grid 10 10 10 -visualize_grid_count -no_shadows

********************************************
RAY TRACING STATISTICS
  total time                 0:00:01
  num pixels                 90000 (300x300)
  scene bounds               (-0.19 0.07 -0.11) -> (0.12 0.37 0.12)
  num grid cells             1000 (10x10x10)
  num non-shadow rays        90000
  num shadow rays            0
  total intersections        90000
  total cells traversed      129844
  rays per second            90000.0
  rays per pixel             1.0
  intersections per ray      1.0
  cells traversed per ray    1.4
********************************************


raytracer -input scene6_bunny_mesh_1k.txt -output out_grid_1k_20x20x20.tga -size 300 300 -grid 20 20 20 -visualize_grid -no_shadows

raytracer -input scene6_bunny_mesh_1k.txt -output out_grid_1k_20x20x20_count.tga -size 300 300 -grid 20 20 20 -visualize_grid_count -no_shadows

********************************************
RAY TRACING STATISTICS
  total time                 0:00:01
  num pixels                 90000 (300x300)
  scene bounds               (-0.19 0.07 -0.12) -> (0.12 0.37 0.12)
  num grid cells             8000 (20x20x20)
  num non-shadow rays        90000
  num shadow rays            0
  total intersections        90000
  total cells traversed      430443
  rays per second            90000.0
  rays per pixel             1.0
  intersections per ray      1.0
  cells traversed per ray    4.8
********************************************


raytracer -input scene7_bunny_mesh_5k.txt -output out_grid_5k_30x30x30.tga -size 300 300 -grid 30 30 30 -visualize_grid -no_shadows

raytracer -input scene7_bunny_mesh_5k.txt -output out_grid_5k_30x30x30_count.tga -size 300 300 -grid 30 30 30 -visualize_grid_count -no_shadows

********************************************
RAY TRACING STATISTICS
  total time                 0:00:01
  num pixels                 90000 (300x300)
  scene bounds               (-0.19 0.07 -0.12) -> (0.12 0.37 0.12)
  num grid cells             27000 (30x30x30)
  num non-shadow rays        90000
  num shadow rays            0
  total intersections        90000
  total cells traversed      791788
  rays per second            90000.0
  rays per pixel             1.0
  intersections per ray      1.0
  cells traversed per ray    8.8
********************************************


raytracer -input scene8_bunny_mesh_40k.txt -output out_grid_40k_50x50x50.tga -size 300 300 -grid 50 50 50 -visualize_grid -no_shadows

raytracer -input scene8_bunny_mesh_40k.txt -output out_grid_40k_50x50x50_count.tga -size 300 300 -grid 50 50 50 -visualize_grid_count -no_shadows

********************************************
RAY TRACING STATISTICS
  total time                 0:00:01
  num pixels                 90000 (300x300)
  scene bounds               (-0.19 0.07 -0.12) -> (0.12 0.37 0.12)
  num grid cells             125000 (50x50x50)
  num non-shadow rays        90000
  num shadow rays            0
  total intersections        90000
  total cells traversed      1583123
  rays per second            90000.0
  rays per pixel             1.0
  intersections per ray      1.0
  cells traversed per ray    17.6
********************************************


raytracer -input scene2_bunny_mesh_200.txt -output out_200_10x10x10.tga -size 300 300 -grid 10 10 10

********************************************
RAY TRACING STATISTICS
  total time                 0:00:11
  num pixels                 90000 (300x300)
  scene bounds               (-0.19 0.07 -0.11) -> (0.12 0.37 0.12)
  num grid cells             1000 (10x10x10)
  num non-shadow rays        90000
  num shadow rays            61594
  total intersections        5799886
  total cells traversed      700221
  rays per second            13781.3
  rays per pixel             1.7
  intersections per ray      38.3
  cells traversed per ray    4.6
********************************************

raytracer -input scene6_bunny_mesh_1k.txt -output out_1k_20x20x20.tga -size 300 300 -grid 20 20 20

********************************************
RAY TRACING STATISTICS
  total time                 0:00:14
  num pixels                 90000 (300x300)
  scene bounds               (-0.19 0.07 -0.12) -> (0.12 0.37 0.12)
  num grid cells             8000 (20x20x20)
  num non-shadow rays        90000
  num shadow rays            62774
  total intersections        6971908
  total cells traversed      1358956
  rays per second            10912.4
  rays per pixel             1.7
  intersections per ray      45.6
  cells traversed per ray    8.9
********************************************

raytracer -input scene7_bunny_mesh_5k.txt -output out_5k_30x30x30.tga -size 300 300 -grid 30 30 30

********************************************
RAY TRACING STATISTICS
  total time                 0:00:20
  num pixels                 90000 (300x300)
  scene bounds               (-0.19 0.07 -0.12) -> (0.12 0.37 0.12)
  num grid cells             27000 (30x30x30)
  num non-shadow rays        90000
  num shadow rays            62984
  total intersections        10369901
  total cells traversed      1977321
  rays per second            7649.2
  rays per pixel             1.7
  intersections per ray      67.8
  cells traversed per ray    12.9
********************************************

raytracer -input scene8_bunny_mesh_40k.txt -output out_40k_50x50x50.tga -size 300 300 -grid 50 50 50

********************************************
RAY TRACING STATISTICS
  total time                 0:00:35
  num pixels                 90000 (300x300)
  scene bounds               (-0.19 0.07 -0.12) -> (0.12 0.37 0.12)
  num grid cells             125000 (50x50x50)
  num non-shadow rays        90000
  num shadow rays            62980
  total intersections        19949589
  total cells traversed      3261568
  rays per second            4370.9
  rays per pixel             1.7
  intersections per ray      130.4
  cells traversed per ray    21.3
********************************************