POV-Ray : Newsgroups : povray.general : Tapering helix : Re: Tapering helix Server Time
29 Jul 2024 12:23:50 EDT (-0400)
  Re: Tapering helix  
From: Le Forgeron
Date: 22 Jun 2011 13:42:57
Message: <4e0229a1$1@news.povray.org>
Le 21/06/2011 23:07, posfan12 nous fit lire :
> I'd like to create a building shaped like a helix that tapers toward the top.
> Can anyone come up with a good method? The helix macros in shapesq don't produce
> the results I expect and they're not solid as far as I can tell.

Do you mean a spiral along a cone ?
Or a rotating square/whatever which get smaller on the top (dimension of
side is reducing like the radius of the cone) ?

(center of the square match the axis of the cone)

you can try rotating a slice while increasing the angle and decreasing
the size.

// untested, 3.6/3.7
union {
#local Side=10;
#local Max_Height=20;
#local Step=0.1;
#local Current=0;
#local Turn=60; /* Degrees of rotation per vertical unit */
#while (Current < Max_Height)
#local AA=<Side * (Max_Height - Current)/Max_Height, Current, Side *
(Max_Height - Current)/Max_Height>;
#local BB=<Side * (Max_Height - Current)/Max_Height, Current+Step, Side
* (Max_Height - Current)/Max_Height>;
box { AA*<-1,1,1>,BB rotate Turn*Current*y }
#local Current=Current+Step;
#end
}


Post a reply to this message

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