POV-Ray : Newsgroups : povray.advanced-users : Shape : Re: Shape Server Time
28 Jul 2024 18:12:22 EDT (-0400)
  Re: Shape  
From: Thies Heidecke
Date: 25 Aug 2004 10:07:57
Message: <412c9d3d$1@news.povray.org>
"Andrew C on Mozilla" <voi### [at] devnull> schrieb im Newsbeitrag
news:412b9b37$1@news.povray.org...
> OK, I was about to post a question... but then I realised, I'm not sure
> if the shape I'm looking for is a parabola or a hyperbola...
>
> Anyway, I was going to ask how I get POV-Ray to draw that shape. (The
> one with two lobes that don't quite meet.) I thought it was in
> shapes.inc somewhere, but I can't seem to find it...

Hi,
it's a hyperboloid
the equation which describes it is:


where a,b,c determine the length/scaling of the axes.
the axis with the plus-sign is at the same time the rotational axis

in SDL you can make this with a quadric:
#declare a=1;
#declare b=2;
#declare c=1;

quadric {
  <-1/(a*a), 1/(b*b), -1/(c*c)>, //  A x^2  + B y^2  + C z^2  +
  <0, 0, 0>,                     //  D xy   + E xz   + F yz   +
  <0, 0, 0>,                     //  G x    + H y    + I z    +
  -1                             //  J
  texture {
    pigment { color rgb 1 }
    finish { diffuse 1 ambient 0 phong 0.5 }
  }
}

In this example the shape is symmetric about the y-axis
and scaled by a factor of two.

> Andrew @ home.
Thies


Post a reply to this message

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