home *** CD-ROM | disk | FTP | other *** search
/ Mega A/V / mega_av.zip / mega_av / GRAPHUTL / POVSCN.ZIP / LEVEL3.ZIP / ROMAN.POV < prev    next >
Text File  |  1992-07-03  |  6KB  |  229 lines

  1. // Persistence Of Vision raytracer version 1.0 sample file.
  2. // By Rick Mallett of Carleton University,  Ottowa.
  3. // First stage of the Tower of Pisa 
  4. // Warning:  This picture can take a very long time to ray trace
  5. // due to the large number of objects.  You have been warned :->  
  6.  
  7. #include "shapes.inc"
  8. #include "colors.inc"
  9. #include "textures.inc"
  10.  
  11. camera {
  12.    location <0.0 25.0 -150.0>
  13.    direction <0.0 0.1 1.0>
  14.    up <0.0 1.0 0.0>
  15.    right <1.3333 0.0 0.0>
  16. }
  17.  
  18. #declare Beam = quadric { Cylinder_Y
  19.    scale <0.5 20.0 0.5>
  20.    translate <2.0 0.0 0.0>
  21. }
  22.  
  23. /* create a sample column for the base of the structure */
  24.  
  25. #declare BaseColumn = object {
  26.    intersection {
  27.       union {
  28.          quadric { Beam }
  29.          quadric { Beam rotate <0.0 -25.7  0.0> }
  30.          quadric { Beam rotate <0.0 -51.4  0.0> }
  31.          quadric { Beam rotate <0.0 -77.1  0.0> }
  32.          quadric { Beam rotate <0.0 -102.8 0.0> }
  33.          quadric { Beam rotate <0.0 -128.5 0.0> }
  34.          quadric { Beam rotate <0.0 -154.2 0.0> }
  35.          quadric { Beam rotate <0.0 -179.9 0.0> }
  36.          quadric { Beam rotate <0.0 -205.6 0.0> }
  37.          quadric { Beam rotate <0.0 -231.3 0.0> }
  38.          quadric { Beam rotate <0.0 -257.0 0.0> }
  39.          quadric { Beam rotate <0.0 -282.7 0.0> }
  40.          quadric { Beam rotate <0.0 -308.4 0.0> }
  41.          quadric { Beam rotate <0.0 -334.1 0.0> }
  42.       }
  43.  
  44.       plane { <0.0 1.0 0.0> 40.0 }
  45.       plane { <0.0 -1.0 0.0> 0.0 }
  46.    }
  47.  
  48.    bounded_by {
  49.       intersection {
  50.          plane { <0.0 1.0 0.0> 40.0 }
  51.          plane { <0.0 -1.0 0.0> 0.0 }
  52.          quadric {
  53.             Cylinder_Y
  54.             scale <2.51 1.0 2.51>
  55.          }
  56.       }
  57.    }
  58.  
  59.    texture {
  60.       Red_Marble
  61.       scale <10.0 10.0 10.0>
  62.       ambient 0.2
  63.       diffuse 0.7
  64.       reflection 0.1
  65.    }
  66.  
  67.    colour red 0.8 green 0.0 blue 0.0
  68.  
  69. }
  70.  
  71. /* and a rectangular pad to serve as a footing for the column */
  72.  
  73. #declare BasePad = object {
  74.    box {
  75.       UnitBox
  76.       scale <4 1 4>
  77.    }
  78.    texture {
  79.       Red_Marble
  80.       scale <10.0 10.0 10.0>
  81.       ambient 0.2
  82.       diffuse 0.7
  83.       reflection 0.1
  84.    }
  85.  
  86.    colour red 0.6 green 0.6 blue 0.4
  87.  
  88. }
  89.  
  90. /* and define a basic arch to span the columns */
  91.  
  92. #declare BaseArch = object {
  93.    intersection {
  94.       quadric { Cylinder_X scale <1.0 12.5 12.5> }
  95.       quadric { Cylinder_X scale <1.0 8.5 8.5> inverse }
  96.       plane { <1.0 0.0 0.0> 2.0 }
  97.       plane { <-1.0 0.0 0.0> 2.0 }
  98.       plane { <0.0 -1.0 0.0> 0.0 }
  99.    }
  100.  
  101.    bounded_by {
  102.       quadric {
  103.          Ellipsoid
  104.          scale <5.0 13.0 13.0>
  105.       }
  106.    }
  107.  
  108.    texture {
  109.       Red_Marble
  110.       scale <10.0 10.0 10.0>
  111.       ambient 0.2
  112.       diffuse 0.7
  113.       reflection 0.1
  114.    }
  115.  
  116.    colour red 0.8 green 0.8 blue 0.8
  117.  
  118. }
  119.  
  120. /* and finally define the first floor floor */
  121.  
  122. #declare BaseFloor = object {
  123.    intersection {
  124.       quadric { Cylinder_Y scale <50.0 50.0 50.0> }
  125.       quadric { Cylinder_Y scale <40.0 40.0 40.0> inverse }
  126.       plane { <0.0 1.0 0.0> 2.0 }
  127.       plane { <0.0 -1.0 0.0> 2.0 }
  128.    }
  129.  
  130.    texture {
  131.       Red_Marble
  132.       scale <10.0 10.0 10.0>
  133.       ambient 0.2
  134.       diffuse 0.7
  135.       reflection 0.1
  136.    }
  137.  
  138.    colour red 0.8 green 0.8 blue 0.6
  139.  
  140. }
  141.  
  142. /* place a ring of 14 columns with footings around the base */
  143.  
  144. #declare FullColumn = composite {
  145.    object { BaseColumn translate <45.0 0.0 0.0>   }
  146.    object { BasePad    translate <45.0 -1.0 0.0>  }
  147.    object { BasePad    translate <45.0 41.0 0.0>  }
  148.    object { BaseArch   translate <45.0 42.0 2.0>
  149.       rotate <0.0 -12.85 0.0>     }
  150. }
  151.  
  152. #declare Level1 = composite {
  153.    composite { FullColumn }
  154.    composite { FullColumn rotate <0.0 -25.7  0.0> }
  155.    composite { FullColumn rotate <0.0 -51.4  0.0> }
  156.    composite { FullColumn rotate <0.0 -77.1  0.0> }
  157.    composite { FullColumn rotate <0.0 -102.8 0.0> }
  158.    composite { FullColumn rotate <0.0 -128.5 0.0> }
  159.    composite { FullColumn rotate <0.0 -154.2 0.0> }
  160.    composite { FullColumn rotate <0.0 -179.9 0.0> }
  161.    composite { FullColumn rotate <0.0 -205.6 0.0> }
  162.    composite { FullColumn rotate <0.0 -231.3 0.0> }
  163.    composite { FullColumn rotate <0.0 -257.0 0.0> }
  164.    composite { FullColumn rotate <0.0 -282.7 0.0> }
  165.    composite { FullColumn rotate <0.0 -308.4 0.0> }
  166.    composite { FullColumn rotate <0.0 -334.1 0.0> }
  167.    composite { FullColumn rotate <0.0 -334.1 0.0> }
  168.    object { BaseFloor translate <0.0 56.5 0.0>   }
  169.  
  170.    bounded_by {
  171.       intersection { 
  172.          quadric { Cylinder_Y scale <55.0 1.0 55.0> }
  173.          plane { <0.0  -1.0  0.0> 0.0 }
  174.          plane { <0.0  1.0   0.0> 60.0 }
  175.       }
  176.    }
  177. }
  178.  
  179. composite { Level1 }
  180.  
  181. /* Add the sky to the picture */
  182. object {
  183.    sphere { <0.0 0.0 0.0> 300.0 }
  184.  
  185.    texture {
  186.       bozo
  187.       turbulence 0.5
  188.       colour_map {
  189.          [0.0 0.6  colour red 0.5 green 0.5 blue 1.0
  190.          colour red 0.5 green 0.5 blue 1.0]
  191.          [0.6 0.8 colour red 0.5 green 0.5 blue 1.0
  192.          colour red 1.0 green 1.0 blue 1.0]
  193.          [0.8 1.001 colour red 1.0 green 1.0 blue 1.0
  194.          colour red 0.8 green 0.8 blue 0.8]
  195.       }
  196.       scale <100.0  20.0  100.0>
  197.       ambient 0.8
  198.       diffuse 0.0
  199.    }
  200.  
  201.    colour red 0.5 green 0.5 blue 1.0
  202.  
  203. }
  204.  
  205. /* Define the desert floor */
  206. object {
  207.    plane { <0.0 1.0 0.0> -2.0 }
  208.  
  209.    texture {
  210.       0.05  /* This value dithers the colours */
  211.       colour red 1.0 green 0.66 blue 0.2
  212.       ripples 0.5
  213.       frequency 2000.0
  214.       scale <50000.0 50000.0 50000.0>
  215.       ambient 0.3
  216.       diffuse 0.7
  217.    }
  218.  
  219.    colour red 1.0 green 0.66 blue 0.2
  220.  
  221. }
  222.  
  223. /* Add a light source */
  224. object {
  225.    light_source { <60.0  50.0  -110.0>
  226.       colour White
  227.    }
  228. }
  229.