POV-Ray : Newsgroups : povray.general : Double Helix : Re: Double Helix Server Time
9 Aug 2024 23:22:53 EDT (-0400)
  Re: Double Helix  
From: Thomas Willhalm
Date: 26 Apr 2000 14:49:28
Message: <qqmog6wofyf.fsf@schlatt.fmi.uni-konstanz.de>
Chris Huff <chr### [at] yahoocom> writes:

> In article <3906DDC6.6A137E88@erols.com>, Rik Kline <rik### [at] erolscom> 
> wrote:
> 
> > Does any one have any code or know of any for a double helix object?
> 
> Try something like this(untested!):
> #macro DoubleHelix(Num, Twists, Height, Radius, MinorRadius, Offset)
>     union {
>         #local J=0;
>         #while(J<Num)
>             sphere {< Radius, Height*J/(Num-1), 0>, MinorRadius
>                 rotate y*360*Twists*J/(Num-1)
>             }
>             sphere {< Radius, Height*J/(Num-1), 0>, MinorRadius
>                 rotate y*360*Twists*J/(Num-1) + y*Offset
>             }
>             #local J=J+1;
>         #end
>     }
> #end

Or use the helix object in the megapatch.

Thomas

-- 
http://thomas.willhalm.de/ (includes pgp key)


Post a reply to this message

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