POV-Ray : Newsgroups : povray.beta-test : Bug in SuperTorus Server Time
2 Nov 2024 15:23:50 EDT (-0400)
  Bug in SuperTorus (Message 1 to 4 of 4)  
From: Redbeard (MDJohnson)
Subject: Bug in SuperTorus
Date: 17 Oct 2001 22:57:26
Message: <3bce4516$1@news.povray.org>
I started playing with the SuperTorus in shapes.inc today and noticed a couple
problems.

First, and easiset to fix (I was able to do it myself) is that the Accuracy
parameter is not used.  Instead, the accuracy is set to 0.01.

Second, if I use a major or minor control of more than 0.5 (exactly) strange
things start happening.  If MinorControl is greater than 0.5, the ST becomes a
solid disc-like thing.  If MajorControl is greator than 0.5, a "plate" covers
3/4 of the object, covering exactly 3 of the four quadrants (I'm not sure which
one is not covered - I'll post test renders to p.b-t.b shortly)  I thought
perhaps it was the contained_by statement, but I enlarged it and it only moves
the plate.

Finally, I would add a default max_gradient of 1 when max_gradient is less than
1 and evaluate is used.  That seems to help with holes most of the time.

Ok, that was more than a couple.  Sorry :-)

Again, I'll post sample renders (and code) to p.b-t.b shortly.

Michael
--
#macro M(D)#local J=strlen(D);#local _=""#while(J>0)#local _=concat(_,substr(D
,J,1))#local J=J-1;#end _#end sphere{z*9,5pigment{rgb x}}#macro N(D,J)text{ttf
"timrom.ttf"M(D)1,0 translate-J}#end#macro O(E,K)#local _=N(E,K)light_source{-
z*9rgb 1projected_through{_}}#end O("leahciM"<1.6,-.3.9>)O("nosnhoJ"<1.6.9.9>)


Post a reply to this message

From: Josh Seagoe
Subject: Re: Bug in SuperTorus
Date: 18 Oct 2001 00:01:06
Message: <3BCE54AC.3010808@smileyface.com>
Redbeard (MDJohnson) wrote:

> Second, if I use a major or minor control of more than 0.5 (exactly) strange
> things start happening.  If MinorControl is greater than 0.5, the ST becomes a
> solid disc-like thing.  If MajorControl is greator than 0.5, a "plate" covers
> 3/4 of the object, covering exactly 3 of the four quadrants (I'm not sure which
> one is not covered - I'll post test renders to p.b-t.b shortly)  I thought
> perhaps it was the contained_by statement, but I enlarged it and it only moves
> the plate.


This can be fixed by changing the function to:
function { ( abs((abs(x)^RP + abs(z)^RP)^(1/RP) - RMj)^CP + abs(y)^CP 
)^(1/CP) - RMn }

Note all the extra "abs()"s.  This changes the shape in some cases 
(control of 2/3 I think), but I think the new shape is probably more 
desireable anyway.


-josh


Post a reply to this message

From: Redbeard (MDJohnson)
Subject: Re: Bug in SuperTorus
Date: 18 Oct 2001 01:02:40
Message: <3bce6270@news.povray.org>
>
> This can be fixed by changing the function to:
> function { ( abs((abs(x)^RP + abs(z)^RP)^(1/RP) - RMj)^CP + abs(y)^CP
> )^(1/CP) - RMn }
>
>
> -josh
>

Thanks, I'll try it.
Michael


Post a reply to this message

From: Redbeard (MDJohnson)
Subject: Re: Bug in SuperTorus
Date: 19 Oct 2001 00:43:16
Message: <3bcfaf64$1@news.povray.org>
"Josh Seagoe" <jos### [at] smileyfacecom> wrote in message
news:3BC### [at] smileyfacecom...
> Redbeard (MDJohnson) wrote:
>
>
> This can be fixed by changing the function to:
> function { ( abs((abs(x)^RP + abs(z)^RP)^(1/RP) - RMj)^CP + abs(y)^CP
> )^(1/CP) - RMn }
>
> Note all the extra "abs()"s.  This changes the shape in some cases
> (control of 2/3 I think), but I think the new shape is probably more
> desireable anyway.
>
>
> -josh
>
It worked.  Thanks!

Michael


Post a reply to this message

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