POV-Ray : Newsgroups : povray.newusers : Elliptical Torus : Re: Elliptical Torus Server Time
29 Jul 2024 10:23:50 EDT (-0400)
  Re: Elliptical Torus  
From: tgl
Date: 2 Mar 2006 17:50:00
Message: <web.4407760b61f3c5399fea01560@news.povray.org>
"Roman Reiner" <lim### [at] gmxde> wrote:
> does this work for you?
>
> camera {
>   location <-5,15,-10>
>   look_at 0
>   angle 45
> }
> light_source {
>   <-5,15,-10>
>   rgb 1
> }
>
> #local a = 5; //semimajor axis
> #local b = 3; //semiminor axis
> #local r = .5; //minor radius
>
> #local n = 20;//number of spheres/accuracy of object
>
> sphere_sweep {
>   cubic_spline
>   n+3,
>   #local i=0;
>   #while(i<=2*pi*(1+2/n))
>     <a*sin(i),0,b*cos(i)>, r
>     #local i=i+(2*pi/n);
>   #end
>   pigment { rgb y }
>   finish { phong 1 }
> }
>
> Regards Roman

Tried the above and as is, it looks good but then I tried the following
variation...

camera {
  location <0,0,-10>
  look_at 0

}
light_source {
  <-5,15,-10>
  rgb 1
}

#local a = 5; //semimajor axis
#local b = 3; //semiminor axis
#local r = .5; //minor radius

#local n = 20;//number of spheres/accuracy of object

sphere_sweep {
  cubic_spline
  n+3,
  #local i=0;
  #while(i<=2*pi*(1+2/n))
    <a*sin(i),0,b*cos(i)>, r
    #local i=i+(2*pi/n);
  #end
  pigment { rgb y }
  finish { phong 1 }
  rotate <-90,0,0>
}

 Is there some kind of distortion happening here or am I seeing things. I
really need an accurate and consistant shape.
 tgl


Post a reply to this message

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