home *** CD-ROM | disk | FTP | other *** search
/ DP Tool Club 11 / CD_ASCQ_11_0294.iso / voxrom / images / kerleau / cafet / cafet.pov next >
Text File  |  1994-01-09  |  5KB  |  148 lines

  1. // Sample File by J. KERLEAU  12-93
  2.  
  3. // ----- COLORS
  4. // ------------
  5. #declare White = color rgb <1,1,1>
  6. #declare Black = color rgb <0,0,0>
  7. #declare Red = color rgb <1,0,0>
  8. #declare Green = color rgb <0,1,0>
  9. #declare Blue = color rgb <0,0,1>
  10. #declare Yellow = color rgb <1,1,0>
  11.  
  12. // ----- TEXTURES
  13. // --------------
  14. #declare Std = finish { ambient 0.3 diffuse 0.7 }
  15. #declare PB_T = texture {
  16.     pigment { Black }
  17.     finish { specular 0.5 roughness 0.15 }
  18. }
  19. #declare PC_T = texture {
  20.     pigment { Black }
  21.     finish {
  22.         ambient 0.3 diffuse 0.2 reflection 0.5 brilliance 15
  23.         specular 1 roughness 0.001 phong 1
  24.     }
  25. }
  26. #declare Glass2 = texture {
  27.     pigment { White filter 1 }
  28.     finish {
  29.         ambient 0 diffuse 0 reflection 0.5 refraction 0.85 ior 1.5
  30.         phong 0.3 phong_size 60
  31.     }
  32. }
  33. #declare Plane_T = texture {
  34.     pigment { Blue }
  35.     finish { ambient 0.3 diffuse 0.7 phong 1 phong_size 250 }
  36. }
  37. #declare Wall_T = texture {
  38.     pigment { White }
  39.     finish { ambient 0.5 diffuse 0.5 phong 1 phong_size 100 }
  40.     normal { bump_map { gif "carreau.gif" bump_size 10 } }
  41.     scale 2
  42. }
  43. #declare Red_Button_T = texture {
  44.     pigment { Red }
  45.     finish { ambient 1 diffuse 0 }
  46. }
  47. #declare Green_Button_T = texture {
  48.     pigment { Green }
  49.     finish { ambient 1 diffuse 0 }
  50. }
  51. #declare Cup_T = texture {
  52.     pigment { White }
  53.     finish { Std }
  54. }
  55.  
  56. // ----- SHAPES
  57. // ------------
  58. #declare Sphere = sphere { <0,0,0>,1 }
  59. #declare PT = union {
  60.     cylinder { <0,11,0>,<0,9,0>,2 texture { PB_T } }
  61.     cylinder { <0,9,0>,<0,7,0>,1.8 texture { PC_T } }
  62.     cylinder { <0,7,0>,<0,5,0>,2 texture { PB_T } }
  63. }
  64. #declare ST0 = intersection { torus { 2.75,0.25 rotate 90*x } plane { -y,0 } }
  65. #declare Struct = union {
  66.     object { ST0 scale <1,1/3,4> translate 11*y }
  67.     cylinder { <-2.75,0,0>,<-2.75,11,0>,0.25 scale <1,1,4> }
  68.     cylinder { <2.75,0,0>,<2.75,11,0>,0.25 scale <1,1,4> }
  69.     box { <-3,5.9,-0.5> <3,6.1,0.5> }
  70.     box { <-3,9.9,-0.5> <3,10.1,0.5> }
  71. }
  72. #declare Coffee_Pot_Top = intersection {
  73.     torus { 1.5,0.5 } torus { 1.5,0.4 inverse }
  74.     cylinder { <0,-1,0>,<0,1,0>,1.5 inverse }
  75.     plane { -y,0 }
  76. }
  77. #declare Coffee_Pot_Base = object { Coffee_Pot_Top rotate 180*x }
  78. #declare Handle = intersection {
  79.     cylinder { <-0.5,2,-2>,<0.5,2,-2>,1 }
  80.     cylinder { <-1,2,-2>,<1,2,-2>,0.8 inverse }
  81.     cylinder { <0,0,0>,<0,4,0>,2 inverse }
  82. }
  83. #declare Coffee_Pot_Body = intersection {
  84.     cylinder { <0,0.5,0>,<0,3,0>,2 }
  85.     cylinder { <0,0,0>,<0,4,0>,1.9 inverse }
  86. }
  87. #declare Coffee_Pot = union {
  88.     object { Coffee_Pot_Top translate 3*y texture { Glass2 } }
  89.     object { Coffee_Pot_Base translate 0.5*y texture { Glass2 } }
  90.     object { Coffee_Pot_Body texture { Glass2 } }
  91.     cylinder { <0,0.5,0>,<0,1,0>,2.0001 open texture { PC_T } }
  92.     cylinder { <0,2.5,0>,<0,3,0>,2.0001 open texture { PC_T } }
  93.     object { Handle translate -0.25*y texture { PB_T } }
  94.     cylinder { <0,0,0>,<0,0.1,0>,1.5 texture { Glass2 } }
  95.     bounded_by { box { <-2.1,-0.1,-3.1> <2.1,3.6,2.1> } }
  96. }
  97. #declare Base0 = cylinder { <0,0,0>,<0,1,0>,4 }
  98. #declare Base1 = union {
  99.     torus { 2.5,0.125 translate y }
  100.     cylinder { <0,1,0>,<0,0.075,0>,2.5 }
  101. }
  102. #declare Coffee_Machine = union {
  103.     object { Struct texture { PC_T } }
  104.     object { PT }
  105.     object { Base0 texture { PB_T } }
  106.     sphere { <0,8.5,-1.8>,0.15 texture { Green_Button_T } }
  107.     sphere { <0,7.5,-1.8>,0.15 texture { Red_Button_T } }
  108.     object { Base1 texture { PC_T } }
  109.     bounded_by { box { <-4.1,-0.1,-4.1> <4.1,13,4.1> } }
  110. }
  111. #declare T0 = intersection {
  112.     cylinder { <0,0.125,0>,<0,1.5,0>,0.875 }
  113.     cylinder { <0,-1,0>,<0,2,0>,0.625 inverse }
  114. }
  115. #declare Handle_Cup = intersection {
  116.     torus { 0.5,0.1 rotate 90*x }
  117.     plane { -x,0 }
  118. }
  119. #declare Cup = union {
  120.     torus { 0.75,0.125 translate 1.5*y }
  121.     object { T0 }
  122.     torus { 0.75,0.125 translate 0.125*y }
  123.     object { Handle_Cup translate <0.7,0.75,0> }
  124. }
  125.  
  126. // ----- SCENE
  127. // -----------
  128. object { Coffee_Machine rotate -20*y translate -2*x }
  129. object { Coffee_Pot rotate -65*y translate <-2,1,0> }
  130. object { Cup texture { Cup_T } translate <4,0,-2> }
  131. box { <-50,-1,-15> <50,0,10> texture { Plane_T } }
  132. plane { z,6 texture { Wall_T } }
  133.  
  134. // ----- CAMERA & LIGHTS
  135. // ---------------------
  136. camera { location <0,8,-15> look_at <0,5.5,0> }
  137. //light_source { <20,20,-20> color White }
  138. light_source {
  139.     <20,20,-20> color White
  140.     spotlight
  141.     point_at <-2,5,0>
  142.     radius 35
  143.     falloff 45
  144.     tightness 20
  145. }
  146. light_source { <-30,20,-10> color rgb <0.5,0.5,0.5> }
  147.  
  148.