home *** CD-ROM | disk | FTP | other *** search
/ CD Actual 22 / PC Actual CD 22.iso / SHARE / prog / POVRAY / CLOCKMOD.ZIP / ANIM1.POV next >
Encoding:
Text File  |  1997-06-24  |  1.3 KB  |  36 lines

  1. // CLOCK MODIFIER: EXAMPLE ANIMATION 1
  2. // ***********************************
  3. // This animation shows how the modified clock can be used to
  4. // translate objects in various ways.  It also shows how the
  5. // clock_repeat option can be used.
  6.  
  7. // CAMERA AND LIGHTS
  8.    camera {location <0, 0, -20> look_at <0, 0, 0> angle 40}
  9.    light_source {<50, 50, -50> rgb 1}
  10.  
  11. // ROD OBJECTS
  12.    #declare Rod = cylinder {-x * 10, x * 10, .2
  13.       pigment {checker rgb <1, 1, 1>, rgb <.5, .5, .5> translate y * .5}}
  14.  
  15.    object {Rod}
  16.    object {Rod translate y * 3}
  17.    object {Rod translate y * -3}
  18.  
  19. // TOP SPHERE (Accelerates from left to right)
  20.    sphere {<0, 0, 0>, 1
  21.       pigment {rgb <1, 0, 0>} finish {phong .5}
  22.       #declare clock_type = "Accelerate" #include "ClockMod.inc"
  23.       translate <-5, 3, 0> + mclock * x * 10}
  24.  
  25. // BOTTOM SPHERE (Decelerates from left to right)
  26.    sphere {<0, 0, 0>, 1
  27.       pigment {rgb <1, 1, 0>} finish {phong .5}
  28.       #declare clock_type = "Decelerate" #include "ClockMod.inc"
  29.       translate <-5, -3, 0> + mclock * x * 10}
  30.  
  31. // MIDDLE SPHERE (Repeated wave motion)
  32.    sphere {<0, 0, 0>, 1
  33.       pigment {rgb <0, 0, 1>} finish {phong .5}
  34.       #declare clock_type = "Wave" #declare clock_repeat = 2 #include "ClockMod.inc"
  35.       translate <-5, 0, 0> + mclock * x * 10}
  36.