|
|
Tor Olav Kristensen wrote:
>
> Below you find the code for my new suggestion.
> The "big" difference is the passing of the
> spike shape trough a variable; "Thing" to
> the macro.
>
> (POV-Ray does not force you to do this, but
> I think this is good programming practice.)
>
I forgot to mention that this enables you to
have the macro accept other shapes too.
Now you can do things like this:
#declare Spike = cone { <0, 0, 0>, 0.2, <0, 1, 0>, 0 }
#declare Grid_1 =
union {
Make_Grid(Spike, 0.5, 6)
}
#declare Grid_2 =
union {
Make_Grid(sphere { y*0.8, 0.3 }, 0.5, 6)
}
difference {
object { Grid_1 }
object { Grid_2 }
rotate 45*x
translate 3*y
pigment { color Red }
}
Tor Olav
--
mailto:tor### [at] hotmailcom
http://www.crosswinds.net/~tok/tokrays.html
Post a reply to this message
|
|