home *** CD-ROM | disk | FTP | other *** search
/ The World of Computer Software / World_Of_Computer_Software-02-385-Vol-1of3.iso / p / ply15dat.zip / SINFN.PI < prev    next >
Text File  |  1992-09-19  |  739b  |  34 lines

  1. // File demonstrating height field function
  2. // Polyray input file: Alexander Enzmann
  3.  
  4. // Define range of frames for animated sequence of images, uncomment the
  5. // next three lines to generate the frames
  6. // start_frame 0
  7. // end_frame 59
  8. // outfile sinsf
  9.  
  10. define theta_offset radians(frame * 6)
  11.  
  12. // Set up the camera
  13. viewpoint {
  14.    from <0,5,-5>
  15.    at <0,0,0>
  16.    up <0,1,0>
  17.    angle 30
  18.    resolution 200, 200
  19.    }
  20.  
  21. // Get various surface finishes
  22. include "..\colors.inc"
  23.  
  24. // Set up background color & lights
  25. background SkyBlue
  26. light <10,10,-10>
  27.  
  28. // Define a sinusoidal surface
  29. object {
  30.    smooth_height_fn 128, 128, -2, 2, -2, 2,
  31.                     0.25 * sin(18.85 * x * z + theta_offset)
  32.    shiny_red
  33.    }
  34.