Descriptions and Samples for the POV-Ray Raytracer by Friedrich A. Lohmüller
    deutsche Version

roof overview Shoji - a Japanese paperwall

Fence

The Construction of a fence by layered textures.

Objects:    "box, clinder".
Methods: "color_map, layered textures, macro"

Construction in details:

Two grids, each of them realized by a color_map (thin dark opaque + wide clear transparent),
are rotated by 45 degrees and -45 degrees. Then they are layered to a fence grid.


 
//----------------------------<<<< grid macro
#macro Raster(RScale, RLine) 
pigment{gradient x scale RScale
        color_map{[0.000   color rgbt<0,0,0,0>]
                  [0+RLine color rgbt<0,0,0,0>]
                  [0+RLine color rgbt<1,1,1,1>]
                  [1-RLine color rgbt<1,1,1,1>]
                  [1-RLine color rgbt<0,0,0,0>]
                  [1.000   color rgbt<0,0,0,0>]
                 }}
finish {ambient 0.1 diffuse 0.9}
#end// of Raster(RScale, RLine)-macro    
//----------------------------------------------
#macro ClearGrid (Rscale )
texture{Raster(1.00,0.04) rotate<0 ,45,0> 
        scale Rscale rotate<90,0,0>} 
texture{Raster(1.00,0.04) rotate<0,-45,0> 
        scale Rscale rotate<90,0,0>}
#end //
//----------------------------------------------
box {<0,0,0>,<2,1.99,0.001>                 
     ClearGrid (0.2)}
//------------------------------------- end ----
Demonstration of how to do:
Sample layered grids 600x450

 
The resulting image:
Sample fence 600x450
Click here for the complete scene description of the demo scene
for POV-Ray: ".txt" file or ".pov" file
Click here for the complete scene description of the scene "fence"
for POV-Ray: ".txt" file or ".pov" file


roof overview Shoji - a Japanese paperwall

© Friedrich A. Lohmüller, 2003     email email: (legacy email redacted)