|
![](/i/fill.gif) |
Christopher James Huff wrote:
You could just leave out the last } bracket, so the
> macro usage would be like:
>
> Torus(< 0, 0, 0>, < 1, 2, 3>, 1, 0.2)
> sturm
> texture {...}
> }
Hey Chris, thanks for the tip. It is ridiculously simple when you look at
it. Hadn't even thought of that.
Dave
Post a reply to this message
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
> Heh heh. I knew I should have qualified that and said basic primitives, in
which
> group I include torus. I was thinking, of course, of the following:
>
> sphere
> box
> cylinder
> cone
The reasons for not including the torii's position in the first few
parameters have to do with the way torus intersections are calculated,
mathematically, at the lowest level. I believe that factoring in a
translation inside the *base* intersection calculation would make the
calculation slower. Translations, on the other hand, are a type of
transformations, which are applied *separately* from the base intersection
calculations, and are only applied when necessary.
Trust me, it makes sense when you work out the math yourself =)
- Slime
[ http://www.slimeland.com/ ]
Post a reply to this message
|
![](/i/fill.gif) |