home *** CD-ROM | disk | FTP | other *** search
/ Amiga MA Magazine 1998 #7 / amigamamagazinepolishissue1998.iso / varia / povray3 / povray3_fpu / povscn / level2 / poolball.pov < prev    next >
Text File  |  1997-12-12  |  2KB  |  145 lines

  1. // Persistence Of Vision raytracer version 3.0 sample file.
  2. // File by Dan Farmer
  3.  
  4. #version 3.0
  5. global_settings { assumed_gamma 2.2 }
  6.  
  7. #include "shapes.inc"
  8. #include "colors.inc"
  9. #include "textures.inc"
  10.  
  11. // Special re-write of "Shiny" declaration.  Will override textures.inc.
  12. #declare Shiny = finish {
  13.    phong 1
  14.    phong_size 200
  15.    reflection 0.25
  16.    ambient 0.15
  17.    diffuse 0.75
  18. }
  19.  
  20. #include "poolball.inc"
  21.  
  22. /* ***************** set up the view & light sources **************************/
  23.  
  24. camera {
  25.    location <0.0, 6.0, -15.0>
  26.    direction <0.0, 0.0, 1.5>
  27.    up  <0.0, 1.0, 0.0>
  28.    right <4/3, 0.0, 0.0>
  29.    look_at <0, -1, 0>
  30. }
  31.  
  32. /* Overhead spotlight */
  33. light_source {
  34.     <0.0, 200.0, -3.0> color White
  35.     spotlight
  36.     point_at <0, 1, 3>
  37.     tightness 800
  38.     radius 8
  39.     falloff 25
  40. }
  41.  
  42. /* ************************** set up the table ********************************/
  43.  
  44. /* Felt table top */
  45. plane { y, -1
  46.    finish {
  47.       crand 0.15
  48.       ambient 0.2
  49.       diffuse 0.8
  50.    }
  51.    pigment { MediumForestGreen }
  52. }
  53.  
  54. /* Cue stick */
  55. object { CueStick
  56.    scale  <0.15, 0.15, 1.0>         /* Skinny and long */
  57.    translate -7.5*z
  58. }
  59.  
  60. /* Cue Ball */
  61. object { Ball
  62.    pigment { White }
  63.    finish {
  64.       Shiny
  65.       crand 0.015
  66.       ambient 0.25
  67.    }
  68.  
  69.    translate -6*z
  70. }
  71.  
  72. /* **************************** set up the balls ********************************/
  73. // (The rotations here are just random values to rotate the stripes)
  74.  
  75. /* Row #1 */
  76. object { _1_Ball }
  77.  
  78. /* Row #2 */
  79. object { _3_Ball
  80.    translate <1.0, 0.0, 1.732>
  81. }
  82.  
  83. object { _10_Ball
  84.    rotate <0.0, 0.0, -80>
  85.    translate <-1.0, 0.0, 1.732>
  86. }
  87.  
  88. /* Row #3 */
  89. object { _11_Ball
  90.    rotate <45.0, -35.0, -12.0>
  91.    translate <2.0, 0.0, 3.464>
  92. }
  93.  
  94. object { _8_Ball
  95.    translate <0.0, 0.0, 3.464>
  96. }
  97.  
  98. object { _5_Ball
  99.    translate <-2.0, 0.0, 3.464 >
  100. }
  101.  
  102.  
  103. /* Row #4 */
  104. object { _2_Ball
  105.    translate <-3.0, 0.0, 5.196 >
  106. }
  107.  
  108. object { _7_Ball
  109.    translate <-1.0, 0.0, 5.196 >
  110. }
  111.  
  112. object { _4_Ball
  113.    translate <1.0, 0.0, 5.196 >
  114. }
  115.  
  116. object { _14_Ball
  117.    rotate <0.0, -15.0, -2.0>
  118.    translate <3.0, 0.0, 5.196 >
  119. }
  120.  
  121.  
  122. /* Row #5 */
  123. object { _15_Ball
  124.    translate <-4.0, 0.0, 6.928 >
  125. }
  126.  
  127. object { _13_Ball
  128.    rotate <-5.0, 11.0, -1.0>
  129.    translate <-2.0, 0.0, 6.928 >
  130. }
  131.  
  132. object { _9_Ball
  133.    rotate <-80.0, -13.0, 29.0>
  134.    translate <0.0, 0.0, 6.928 >
  135. }
  136.  
  137. object { _12_Ball
  138.    rotate <15.0, 15.0, -2.0>
  139.    translate <2.0, 0.0, 6.928>
  140. }
  141.  
  142. object { _6_Ball
  143.    translate <4.0, 0.0, 6.928>
  144. }
  145.