home *** CD-ROM | disk | FTP | other *** search
- /*
- this was intended as a speedtest, but it's not a very good benchmark.
- */
- /*
-
- camera1: box 50x50x5: 67 seconds, raw
- sphere 50x50x5: 46 seconds
- algquad 50x50x5: 105 seconds
- quad 50x50x5: 88 secs (huh?)
-
- comments:
- - tracing a raw scene file takes about 0.4 ms/ray.
- - too much time is spent doing alloc() calls.
- - The algebraic is pretty good! only 20% slower than the quad!
- (this of course has something to do with the big number of 0's being
- multiplied, and the relative inefficiency of the supporting routines
- such as add_to_queue, get_new_queue.)
-
- */
-
- // note: these timings were based on the Mess dos compile, and on version 2.4
- // or 2.5
-
-
- #declare camera1 = camera {
- location <0, 0, -10>
- direction <0 , 0, 2>
- sky <0, 1, 0>
- fov 40
- }
-
- #declare camera2 = camera {
- location <0, 0, -10>
- direction <0, 0, -2>
- sky <0, 1, 0>
- fov 40
- }
-
- camera { camera1 }
-
- #declare white = color red 1.0 green 1.0 blue 1.0
- #declare ShinyBlue = texture {
- ambient color blue 0.2
- diffuse color blue 0.7 red 0.2 green 0.2
- specular color white
- roughness 0.1
- }
-
- #declare algquad = object {
- algebraic { $ x^2 + y^2 + z^2 -1 $ }
- }
-
- #declare quad = object {
- quadric { <1, 1, 1>, <0, 0, 0>, <0, 0, 0>, -1 }
- }
-
- #declare testbox1 = object {
- box { <-1, -1, -1>, <1, 1, 1> scale <0.8, 0.8, 0.8> }
- }
-
- #declare testbox2 = object {
- box { <-0.8, -0.8, -0.8>, <0.8, 0.8, 0.8> }
- }
-
- #declare sph = object {
- sphere { <0, 0, 0>, 1 }
- }
-
- #declare testobj = object { algquad
- texture { ShinyBlue }
- }
- //#declare testobj = object { sph }
- //#declare testobj = object { testbox2 }
-
- object { testobj }
- object { testobj }
- object { testobj }
- object { testobj }
- object { testobj }
- object { testobj }
- object { testobj }
- object { testobj }
- object { testobj }
- object { testobj }
-
-
-
-
-
-
-