home *** CD-ROM | disk | FTP | other *** search
/ Amiga MA Magazine 1998 #7 / amigamamagazinepolishissue1998.iso / varia / povray3 / povray3_fpu / pov3demo / surfaces / spiral2a.pov < prev    next >
Text File  |  1997-12-12  |  3KB  |  151 lines

  1. // Persistence Of Vision raytracer version 3.0 sample file.
  2. // Demo using the spiral2 texture ... by Dieter Bayer, May 1994
  3. //
  4. // 9 discs with different spiral2 textures.
  5. //
  6. // The scaling factor of the texture, i.e. the number of turns
  7. // one "arm" of the spiral makes, decreases from left to right.
  8. //
  9. // The number of "arms" of the spiral,
  10. // increases from top to bottom.
  11. //
  12.  
  13. #version 3.0
  14. global_settings { assumed_gamma 2.2 }
  15.  
  16. #include "colors.inc"
  17. #include "shapes.inc"
  18.  
  19. /* factors used for positioning the discs */
  20. #declare X = 2.1 #declare Y = 2.1
  21.  
  22. /* arms used */
  23. #declare O1 = 3
  24. #declare O2 = 6
  25. #declare O3 = 9
  26.  
  27. /* scaling used */
  28. #declare S1 = 100
  29. #declare S2 = 1
  30. #declare S3 = 0.2
  31.  
  32. /* Spiral 1 */
  33. #declare Spiral1 =
  34. texture {
  35.   pigment {
  36.     spiral2 O1
  37.     color_map { [0.0, 1.0  color Red color Green] }
  38.   }
  39.   finish { ambient 1 }
  40.   scale <S1, S1, S1>
  41. }
  42.  
  43. /* Spiral 2 */
  44. #declare Spiral2 =
  45. texture {
  46.   pigment {
  47.     spiral2 O1
  48.     color_map { [0.0, 1.0  color Red color Green] }
  49.   }
  50.   finish { ambient 1 }
  51.   scale <S2, S2, S2>
  52. }
  53.  
  54. /* Spiral 3 */
  55. #declare Spiral3 =
  56. texture {
  57.   pigment {
  58.     spiral2 O1
  59.     color_map { [0.0, 1.0  color Red color Green] }
  60.   }
  61.   finish { ambient 1 }
  62.   scale <S3, S3, S3>
  63. }
  64.  
  65. /* Spiral 4 */
  66. #declare Spiral4 =
  67. texture {
  68.   pigment {
  69.     spiral2 O2
  70.     color_map { [0.0, 1.0  color Red color Green] }
  71.   }
  72.   finish { ambient 1 }
  73.   scale <S1, S1, S1>
  74. }
  75.  
  76. /* Spiral 5 */
  77. #declare Spiral5 =
  78. texture {
  79.   pigment {
  80.     spiral2 O2
  81.     color_map { [0.0, 1.0  color Red color Green] }
  82.   }
  83.   finish { ambient 1 }
  84.   scale <S2, S2, S2>
  85. }
  86.  
  87. /* Spiral 6 */
  88. #declare Spiral6 =
  89. texture {
  90.   pigment {
  91.     spiral2 O2
  92.     color_map { [0.0, 1.0  color Red color Green] }
  93.   }
  94.   finish { ambient 1 }
  95.   scale <S3, S3, S3>
  96. }
  97.  
  98. /* Spiral 7 */
  99. #declare Spiral7 =
  100. texture {
  101.   pigment {
  102.     spiral2 O3
  103.     color_map { [0.0, 1.0  color Red color Green] }
  104.   }
  105.   finish { ambient 1 }
  106.   scale <S1, S1, S1>
  107. }
  108.  
  109. /* Spiral 8 */
  110. #declare Spiral8 =
  111. texture {
  112.   pigment {
  113.     spiral2 O3
  114.     color_map { [0.0, 1.0  color Red color Green] }
  115.   }
  116.   finish { ambient 1 }
  117.   scale <S2, S2, S2>
  118. }
  119.  
  120. /* Spiral 9 */
  121. #declare Spiral9 =
  122. texture {
  123.   pigment {
  124.     spiral2 O3
  125.     color_map { [0.0, 1.0  color Red color Green] }
  126.   }
  127.   finish { ambient 1 }
  128.   scale <S3, S3, S3>
  129. }
  130.  
  131. camera {
  132.   location <0, 0, -6.5>
  133.   right <4/3, 0, 0>
  134.   up <0, 1, 0>
  135.   sky <0, 1, 0>
  136.   direction <0, 0, 1>
  137. }
  138.  
  139. background { color SkyBlue }
  140.  
  141. disc { <0, 0, 0>, <0, 0, 1>, 1 texture { Spiral1 } translate <-1*X, +1*Y, 0> }
  142. disc { <0, 0, 0>, <0, 0, 1>, 1 texture { Spiral2 } translate < 0*X, +1*Y, 0> }
  143. disc { <0, 0, 0>, <0, 0, 1>, 1 texture { Spiral3 } translate <+1*X, +1*Y, 0> }
  144. disc { <0, 0, 0>, <0, 0, 1>, 1 texture { Spiral4 } translate <-1*X,  0*Y, 0> }
  145. disc { <0, 0, 0>, <0, 0, 1>, 1 texture { Spiral5 } translate < 0*X,  0*Y, 0> }
  146. disc { <0, 0, 0>, <0, 0, 1>, 1 texture { Spiral6 } translate <+1*X,  0*Y, 0> }
  147. disc { <0, 0, 0>, <0, 0, 1>, 1 texture { Spiral7 } translate <-1*X, -1*Y, 0> }
  148. disc { <0, 0, 0>, <0, 0, 1>, 1 texture { Spiral8 } translate < 0*X, -1*Y, 0> }
  149. disc { <0, 0, 0>, <0, 0, 1>, 1 texture { Spiral9 } translate <+1*X, -1*Y, 0> }
  150.  
  151.