|
|
"Kenneth" <kdw### [at] gmailcom> wrote:
> "Kenneth" <kdw### [at] gmailcom> wrote:
>
> >
> > My understanding (from the docs) is that a function takes only a 'slice' of a
> > pattern in the x/y plane, by definition...
>
> ....for use in a height_field, that is! Sorry if I didn't make that clear.
#declare PigM=function{pigment{image_map{ tga "FinalB.tga"}}}
#declare Dirt =
function(x,z){select(PigM(x,1-z,0).blue,0,0,PigM(x,1-z,0).blue)}
height_field {function 400,400{ Dirt(x,y) }...
I think maybe what's going on there is much like passing values into a macro
using macro arguments.
he's passing (x, y) into Dirt () when he invokes it through the hf declaration.
and so Dirt sees 2 values, and assigns them to (x, z) in its definition.
Confusing, and needs checking to verify, but that's my take at 6:30am. ;)
- BW
Post a reply to this message
|
|