home *** CD-ROM | disk | FTP | other *** search
- //FIG2-1.PI
-
- include "d:\polyray\include\colors.inc"
- include "d:\polyray\include\texture.inc"
- include "d:\polyray\include\stones.inc"
-
- viewpoint {
- from <0, 10, -20.0>
- at <0.0, 2.5, 10>
- up <0.0, 1.0, 0.0>
- angle 30
- aspect 1.6
- }
-
- // LIGHT_SOURCE
- light <-10, 10, -10>
-
- haze 0.95, 20, black
-
- // Agate texture to use for the colour map changes
- define my_agate
- texture {
- noise surface {
- ambient 0.4
- diffuse 0.6
- specular white, 0.2
- microfacet Cook 4
- position_fn position_objectx
- position_scale 1.1
- lookup_fn lookup_sawtooth
- octaves 3
- turbulence 2
- color_map(
- [0.0, 0.3, <0, 0, 0.9>,0, <0, 0, 0.8>, 0.5]
- [0.3, 1, <0, 0, 0.8>, 0.5, <0, 0, 0.4>, 1])
- }
- scale <0.5, 0.5, 0.5>
- }
-
- // PLANE (Polygon)
- object {
- polygon 4, <-100,0,100>, <-100,0,-100>, <100,0,-100>, <100,0,100>
- translate <0, -2.5, 0>
- texture{ checker bumpy_green, blue_ripple
- scale <5, 5, 5>}
- }
-
- // SPHERE - normal blue agate
- object {
- sphere <-7.0, 2.5, 6.0>, 3.0
- sapphire_agate
- }
-
- // SPHERE - normal blue agate
- object {
- sphere <0.0, 2.5, 6.0>, 3.0
- texture{checker matte_white, matte_black}
- }
-
- // SPHERE - blue agate using my colour map
- object {
- sphere <7.0, 2.5, 6.0>, 3.0
- texture{
- layered
- my_agate,
- texture{ checker matte_white, matte_black}
- }
- }
-
-