home *** CD-ROM | disk | FTP | other *** search
/ Ray Tracing Box / RAY_CD.mdf / raytrace / _pov_dat / plmdat / plmdat.pov < prev    next >
Text File  |  1993-06-24  |  7KB  |  304 lines

  1. // Persistence of Vision Raytracer
  2. #include "colors.inc"
  3. #include "shapes.inc"
  4. #include "textures.inc"
  5.  
  6. #declare Limestone1 = color red 0.941 green 0.871 blue 0.761
  7.  
  8. camera {
  9.    location  <4 8.5 -14>
  10.    direction <0.0 0.0  1.5>
  11.    up        <0.0  1.0  0.0>
  12.    right     <1.33333 0.0 0.0>
  13.    look_at   <0.0 6.0 0.0>
  14. }
  15.  
  16.  
  17. object {light_source {<10 30 -30> color White}}
  18.  
  19. fog {120 color SkyBlue}
  20.  
  21. object {
  22.    sphere {<0 0 0> 1000}
  23.    texture {
  24.       color SkyBlue
  25.       ambient 1.0 diffuse 0.0
  26.    }
  27. }
  28.  
  29. object {
  30.    plane {<0 1 0> 0 }
  31.    texture {checker color Gray80 color Gray60 scale <3 1 1.6>}
  32. }
  33.  
  34. //----------------------------------------------------------------------------      
  35. // potted palm 
  36. // This is the palm plant used in Altar.gif, available in the GRAPHDEV
  37. // forum of Compuserve.  It is made of flattened shperiods, clipped by 
  38. // a clynder, like crescent moons.  These are scaled and arranged in a 
  39. // fan-like manner.  The stems are cones with thier points cut off.
  40. //----------------------------------------------------------------------------      
  41.  
  42. #declare frond = object {
  43.    quadric {
  44.       Ellipsoid
  45.       scale <2 2 0.2>
  46.       translate <0 -1.9 0>
  47.    }
  48.    clipped_by {
  49.       quadric {
  50.          Cylinder_Z inverse
  51.          scale <2.5 2.5 1>
  52.          translate <0 -2.5 0>
  53.       }
  54.    }
  55.  
  56.    translate <1.225 0.325 0>
  57.    rotate <0 0 -10>
  58.    
  59.    texture {
  60.       onion
  61.       turbulence 0.1
  62.       color_map {
  63.          [0.0 0.4 color SeaGreen  color SeaGreen]
  64.          [0.4 0.5 color SeaGreen  color DarkGreen]
  65.          [0.5 1.0 color DarkGreen color DarkGreen]
  66.       }
  67.       //ambient 0.2
  68.  
  69.       bumps 1.0
  70.       scale <4 4 0.1>
  71.       phong 1.0 phong_size 20
  72.    }
  73.  
  74. }
  75.  
  76. #declare fronds = composite {
  77.    object {
  78.       frond
  79.    }
  80.    object {
  81.       frond
  82.       scale <0.9 1 1>
  83.       rotate <0 15 0>
  84.    }
  85.    object {
  86.       frond
  87.       scale <0.9 1 1>
  88.       rotate <0 -15 0>
  89.    }
  90.    object {
  91.       frond
  92.       scale <0.8 1 1>
  93.       rotate <0 30 0>
  94.    }
  95.    object {
  96.       frond
  97.       scale <0.8 1 1>
  98.       rotate <0 -30 0>
  99.    }
  100.    object {
  101.       frond
  102.       scale <0.6 1 1>
  103.       rotate <0 45 0>
  104.    }
  105.    object {
  106.       frond
  107.       scale <0.6 1 1>
  108.       rotate <0 -45 0>
  109.    }
  110.    object {
  111.       frond
  112.       scale <0.5 1 1>
  113.       rotate <0 60 0>
  114.    }
  115.    object {
  116.       frond
  117.       scale <0.5 1 1>
  118.       rotate <0 -60 0>
  119.    }
  120.    object {
  121.       frond
  122.       scale <0.4 1 1>
  123.       rotate <0 80 0>
  124.    }
  125.    object {
  126.       frond
  127.       scale <0.4 1 1>
  128.       rotate <0 -80 0>
  129.    }
  130.    object {
  131.       frond
  132.       scale <0.3 1 1>
  133.       rotate <0 100 0>
  134.    }
  135.    object {
  136.       frond
  137.       scale <0.3 1 1>
  138.       rotate <0 -100 0>
  139.    }
  140.  
  141.    bounded_by {sphere {<0 0 0> 2 translate <1 0 0>}}
  142. }
  143.  
  144.  
  145. #declare potted_palm = composite {
  146. // pot   
  147.    object {
  148.       union {
  149.          intersection {
  150.             quadric {Ellipsoid scale <1 0.6 1>}
  151.             plane {<0 1 0> 0 inverse}
  152.          }
  153.          intersection {
  154.             quadric {Ellipsoid scale <1 1.6 1>}
  155.             plane {<0 1 0> 0}
  156.             plane {<0 1 0> -1.4 inverse}
  157.          }
  158.       }
  159.       clipped_by {sphere {<0 0 0> 0.5 inverse translate <0 0.6 0>}}
  160.       translate <0 1.4 0>
  161.  
  162.       texture {
  163.          image_map {gif "vase.gif" map_type 2}
  164.          rotate <0 -90 0>
  165.          wrinkles 1.0
  166.          phong 0.25 phong_size 50
  167.          scale <1 2.2 1>
  168.       }
  169.    }
  170.    
  171. // branches   
  172.    composite {
  173.       composite {   
  174.          object {
  175.             intersection {Cone_Y scale <0.1 5 0.1> translate <0 5 0>}
  176.             clipped_by {plane {<0 1 0> 5}}
  177.             texture {color DarkGreen}
  178.          }
  179.          composite {
  180.             fronds
  181.             rotate <0 0 40>
  182.             translate <0 5 0>
  183.          }
  184.          rotate <0 0 -45>
  185.       }
  186.  
  187.       composite {
  188.          object {
  189.             intersection {Cone_Y scale <0.1 4.2 0.1> translate <0 4.2 0>}
  190.             clipped_by {plane {<0 1 0> 4.2}}
  191.             texture {color DarkGreen}
  192.          }
  193.          composite {
  194.             fronds
  195.             rotate <0 0 55>
  196.             translate <0 4.2 0>
  197.          }
  198.          rotate <0 0 -25>
  199.          rotate <0 35 0>
  200.       }
  201.       composite {
  202.          object {
  203.             intersection {Cone_Y scale <0.1 5.6 0.1> translate <0 5.6 0>}
  204.             clipped_by {plane {<0 1 0> 5.6}}
  205.             texture {color DarkGreen}
  206.          }
  207.          composite {
  208.             fronds
  209.             rotate <0 0 50>
  210.             translate <0 5.6 0>
  211.          }
  212.          rotate <0 0 -28>
  213.          rotate <0 -45 0>
  214.       }
  215.  
  216.       composite {
  217.          object {
  218.             intersection {Cone_Y scale <0.1 5.4 0.1> translate <0 5.4 0>}
  219.             clipped_by {plane {<0 1 0> 5.4}}
  220.             texture {color DarkGreen}
  221.          }
  222.          composite {
  223.             fronds
  224.             rotate <0 0 65>
  225.             translate <0 5.4 0>
  226.          }
  227.          rotate <0 0 -20>
  228.          rotate <0 25 0>
  229.       }
  230.       composite {
  231.          object {
  232.             intersection {Cone_Y scale <0.1 5.8 0.1> translate <0 5.8 0>}
  233.             clipped_by {plane {<0 1 0> 5.8}}
  234.             texture {color DarkGreen}
  235.          }
  236.          composite {
  237.             fronds
  238.             rotate <0 0 70>
  239.             translate <0 5.8 0>
  240.          }
  241.          rotate <0 0 -15>
  242.          rotate <0 -30 0>
  243.       }
  244.  
  245.       composite {
  246.          object {
  247.             intersection {Cone_Y scale <0.1 6.4 0.1> translate <0 6.4 0>}
  248.             clipped_by {plane {<0 1 0> 6.4}}
  249.             texture {color DarkGreen}
  250.          }
  251.          composite {
  252.             fronds
  253.             rotate <0 0 77>
  254.             translate <0 6.4 0>
  255.          }
  256.       }
  257.  
  258.       rotate <0 90 0>
  259.       translate <0 1.75 0>
  260.    }
  261. }
  262.   
  263. composite {
  264.   potted_palm 
  265. }
  266.  
  267. //----------------------------------------------------------------------------      
  268. // columns
  269. //----------------------------------------------------------------------------      
  270.  
  271. declare column = composite {
  272.    object {
  273.       intersection {Disk_Y translate <0 1 0> scale <1 1.5 1>}
  274.       texture {color Limestone1 wrinkles 1.0}
  275.    }
  276.    object {
  277.       intersection {Disk_Y translate <0 1 0> scale <1.05 1.5 1.02>}
  278.       texture {color Limestone1 wrinkles 1.0}
  279.       translate <0 3.1 0>
  280.    }
  281.    object {
  282.       intersection {Disk_Y translate <0 1 0> scale <0.95 1.5 0.95>}
  283.       texture {color Limestone1 wrinkles 1.0}
  284.       translate <0 6.2 0>
  285.    }
  286.    object {
  287.       intersection {Disk_Y translate <0 1 0> scale <1.05 1.5 1.0>}
  288.       texture {color Limestone1 wrinkles 1.0}
  289.       translate <0 9.3 0>
  290.    }
  291.    
  292.    object {
  293.       quadric {Cylinder_Y scale <0.9 0.9 0.9>}
  294.       texture {color Gray30 dents 1 scale <0.1 0.1 0.1>}
  295.    }
  296. }
  297.  
  298. //columns
  299. composite {column translate <-12 0 12>}
  300. composite {column rotate <0 60 0> translate <-6 0 12>}
  301. composite {column rotate <0 120 0> translate <0 0 12>}
  302. composite {column rotate <0 240 0> translate <6 0 12>}
  303.  
  304.