home *** CD-ROM | disk | FTP | other *** search
/ DP Tool Club 16 / CD_ASCQ_16_0994.iso / news / 4613 / lamp.rrt < prev    next >
Text File  |  1980-01-12  |  1KB  |  78 lines

  1. // Real Ray Tracer
  2. // A demo of bounding volumes.
  3.  
  4. #include "colors.inc"
  5. #include "textures.inc"
  6. #include "shapes.inc"
  7.  
  8. object {
  9.   bound {
  10.     difference {
  11.       intersection {
  12.         object { Cylinder_Y scale <0.3 1 0.3> }
  13.         slab { <0 1 0> -0.5 0.5 }
  14.       }
  15.       union {
  16.         sphere { <0 0 -0.3> 0.2 }
  17.         object { Cylinder_Y scale <0.2828 1 0.2828> }
  18.       }
  19.     }
  20.   }
  21.   by sphere { <0 0 0> 0.6 }
  22.   texture {
  23.     image_map { <-0.5 -0.5 0> <1 0 0> <0 1 0> 1 "marble.tga" }
  24.     ambient 0.35
  25.     phong 0.25
  26.     phong_size 90
  27.   }
  28. }
  29.  
  30. object {
  31.   plane { <1 0 -0.5> -1.25 }
  32.   texture { Mirror }
  33. }
  34.  
  35. object {
  36.   plane { <-1 0 -0.5> -1.25 }
  37.   texture { Mirror }
  38. }
  39.  
  40. object {
  41.   plane { <0 0 -1> -0.5 }
  42.   texture {
  43.     checker color Yellow color Violet
  44.     scale <0.2 0.2 0>
  45.     ambient 0.15
  46.     diffuse 0.25
  47.   }
  48. }
  49.  
  50. object {
  51.   plane { <0 1 0> -1.5 }
  52.   texture {
  53.     checker color Yellow color red 1.0 blue 0.75
  54.     scale <0.3 0 0.3>
  55.     ambient 0.15
  56.     diffuse 0.25
  57.   }
  58. }
  59.  
  60. camera {
  61.   location  <0 0 -3>
  62.   direction <0 0  3>
  63. }
  64.  
  65. environment {
  66.   background color Blue
  67. }
  68.  
  69. object {
  70.   light_source { <1.25 6.7 -7.5> color White }
  71. }
  72.  
  73. object {
  74.   light_source { <0 0.1 0> color White }
  75. }
  76.  
  77. end.
  78.