POV-Ray : Newsgroups : povray.text.scene-files : "Leftovers" Source Code : Re: "Leftovers" Source Code Server Time
28 Jul 2024 14:24:51 EDT (-0400)
  Re: "Leftovers" Source Code  
From: Tor Olav Kristensen
Date: 19 Apr 2000 10:35:36
Message: <38FDC2FB.B2F52BBF@online.no>
Tor Olav Kristensen wrote:

> ...
> By the strange behaviour of the torus shape when the minor radius is
> greater than the major radius.
>
> The latter can be seen when such a torus is subtracted from another
> shape in a CSG operation. (This behaviour can be exploited if one
> wish to make "concave cylinders" or "cigars".)

Sorry. Correction: "convex cylinders"

To get a "cigar", try this:

#declare CigarRadius = 0.5;
#declare MinorRadius = 26;
#declare MajorRadius = MinorRadius - CigarRadius;

difference {
  sphere { <0,0,0>, sqrt(pow(MinorRadius, 2)-pow(MajorRadius, 2))}
  torus { MajorRadius, MinorRadius }
}

The cigar you get from this appears to be hollow (?).
So if you try to do further CSG operations with it you may not get
the desired result.

Tor Olav

mailto:tor### [at] hotmailcom
http://www.crosswinds.net/~tok/tokrays.html


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.