home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 1995 January / pcw-0195.iso / polyray / dat / texture / addmaps1.pi < prev    next >
Text File  |  1994-12-31  |  476b  |  30 lines

  1. // Add two color maps together
  2.  
  3. // Set up the camera
  4. viewpoint {
  5.    from <0,0,-8>
  6.    at <0,0,0>
  7.    up <0,1,0>
  8.    angle 45
  9.    resolution 256, 256
  10.    }
  11.  
  12. background <0, 0, 0>
  13. light <-10,3, -20>
  14.  
  15. include "../colors.inc"
  16.  
  17. static define wood_fn3 sawtooth(3 * sqrt(x*x+y*y))
  18.  
  19. define add_tex1
  20. texture {
  21.    special shiny {
  22.       color (red_marble_map[agate_fn] + jade_color_map[wood_fn3]) / 2
  23.       }
  24.    }
  25.  
  26. object {
  27.    sphere <0, 0, 0>, 2
  28.    add_tex1
  29.    }
  30.