POV-Ray : Newsgroups : povray.advanced-users : Creating Spheres of Triangles Server Time
4 Nov 2024 21:26:01 EST (-0500)
  Creating Spheres of Triangles (Message 1 to 10 of 20)  
Goto Latest 10 Messages Next 10 Messages >>>
From: Lars W 
Subject: Creating Spheres of Triangles
Date: 30 Jun 1999 19:49:45
Message: <377aad19@news.povray.org>
Hi

I wan't to construct an Sphere out of triangles ,( i know the standard
POV-Sphere is faster and better and
so on, but i need a trianglesphere ), does anybody know of resources, or has
an tutorial by him self
for doing that. it should be possible to say, how complex the sphere should
be, and it should
NOT look like an globe, best would be an sphere out of evenly sized
triangles.

thanks in advance.

Lars Wolter


Post a reply to this message

From: Ken
Subject: Re: Creating Spheres of Triangles
Date: 30 Jun 1999 20:02:10
Message: <377AAFC2.7B031B6@pacbell.net>
"Lars W." wrote:
> 
> Hi
> 
> I wan't to construct an Sphere out of triangles ,( i know the standard
> POV-Sphere is faster and better and
> so on, but i need a trianglesphere ), does anybody know of resources, or has
> an tutorial by him self
> for doing that. it should be possible to say, how complex the sphere should
> be, and it should
> NOT look like an globe, best would be an sphere out of evenly sized
> triangles.
> 
> thanks in advance.
> 
> Lars Wolter

  I could easily make you a few triangle spheres using different parameters.
I have a couple of different programs that can do this but I have no pov
script that can accomplish this.

  For an example download my disco ball source with has a triangle based
sphere. It is located in the following location:

    Subject: Reflecting Mirrored Ball Scene
       Date: Sun, 21 Mar 1999 16:20:32 -0800
       From: Ken <tyl### [at] pacbellnet>
 Newsgroups: povray.binaries.scene-files


  You might also be able to fake it using a prism object.

-- 
Ken Tyler

mailto://tylereng@pacbell.net


Post a reply to this message

From: Edward C 
Subject: Re: Creating Spheres of Triangles
Date: 1 Jul 1999 03:35:52
Message: <377b1a58@news.povray.org>
I think your best bet is a dodecahedron, a regular shape made from 20
equilateral triangles.  From there you could sub-divide the faces at will to
however many triangles you want.  See also the previous thread titled "How
to distribute points equally on a sphere surface?".


Post a reply to this message

From: Nieminen Mika
Subject: Re: Creating Spheres of Triangles
Date: 1 Jul 1999 05:28:24
Message: <377b34b8@news.povray.org>
Lars W. <lar### [at] snafude> wrote:
: I wan't to construct an Sphere out of triangles ,( i know the standard
: POV-Sphere is faster and better and
: so on, but i need a trianglesphere ), does anybody know of resources, or has
: an tutorial by him self
: for doing that. it should be possible to say, how complex the sphere should
: be, and it should
: NOT look like an globe, best would be an sphere out of evenly sized
: triangles.

  Distributing objects evenly on the surface of a sphere is a non-trivial
task.
  If making a earth-looking globe (with latitude and longitude lines) is
enough, that's pretty easy with povray (you need some math, though).
Something like this:

#declare Radius=1;
#declare Size1=20;
#declare Size2=10;

mesh
{ #declare Ind2=0;
  #while(Ind2<Size2)
    #declare Ang2_1=pi*Ind2/Size2;
    #declare Ang2_2=pi*(Ind2+1)/Size2;
    #declare Ind1=0;
    #while(Ind1<Size1)
      #declare Ang1_1=2*pi*Ind1/Size1;
      #declare Ang1_2=2*pi*(Ind1+1)/Size1;
      #declare P1=<Radius*(sin(Ang1_1)*sin(Ang2_1)),
                   Radius*cos(Ang2_1),
                   Radius*(cos(Ang1_1)*sin(Ang2_1))>;
      #declare P2=<Radius*(sin(Ang1_2)*sin(Ang2_1)),
                   Radius*cos(Ang2_1),
                   Radius*(cos(Ang1_2)*sin(Ang2_1))>;
      #declare P3=<Radius*(sin(Ang1_2)*sin(Ang2_2)),
                   Radius*cos(Ang2_2),
                   Radius*(cos(Ang1_2)*sin(Ang2_2))>;
      #declare P4=<Radius*(sin(Ang1_1)*sin(Ang2_2)),
                   Radius*cos(Ang2_2),
                   Radius*(cos(Ang1_1)*sin(Ang2_2))>;
      triangle { P1,P2,P3 }
      triangle { P1,P3,P4 }
      #declare Ind1=Ind1+1;
    #end
    #declare Ind2=Ind2+1;
  #end
}

-- 
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):5;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/


Post a reply to this message

From: Chris Huff
Subject: Re: Creating Spheres of Triangles
Date: 1 Jul 1999 07:59:10
Message: <377B5915.C6B3276C@compuserve.com>
Um, isn't a dodecahedron composed of 12 pentagons? If that is the case,
it wouldn't have 20 equilateral triangles, but 60 congruent isosceles
triangles.


Post a reply to this message

From: Ron Parker
Subject: Re: Creating Spheres of Triangles
Date: 1 Jul 1999 09:06:10
Message: <377b67c2@news.povray.org>
On Thu, 1 Jul 1999 17:35:56 +1000, Edward C. wrote:
>I think your best bet is a dodecahedron, a regular shape made from 20
>equilateral triangles.  

You're thinking of an icosahedron.  A dodecahedron has 12 sides.  If
you download my golf ball code from http://www2.fwi.com/~parkerr/traces.html
you'll find that it subdivides an icosahedron to generate the centers
for the dimples; perhaps the original poster could adapt it to his needs.


Post a reply to this message

From: Alberto
Subject: Re: Creating Spheres of Triangles
Date: 1 Jul 1999 11:28:47
Message: <377B89A3.8E70F961@ma.usb.ve>
I've posted the second iteration of a version of your idea in the binaries
news. I have to say that it looks
a little bit strange.

Alberto.

"Edward C." wrote:

> I think your best bet is a dodecahedron, a regular shape made from 20
> equilateral triangles.  From there you could sub-divide the faces at will to
> however many triangles you want.  See also the previous thread titled "How
> to distribute points equally on a sphere surface?".


Post a reply to this message

From: Edward C 
Subject: Re: Creating Spheres of Triangles
Date: 1 Jul 1999 20:23:47
Message: <377c0693@news.povray.org>
OK, OK, so geometry was never my favourite maths topic (calculus is my
thing).  The great thing about the 'net is that you can embarras yourself in
front of so many people at once.


Post a reply to this message

From: Edward C 
Subject: Re: Creating Spheres of Triangles
Date: 1 Jul 1999 20:37:09
Message: <377c09b5@news.povray.org>
But there are other ways to subdivide...

Alberto wrote in message <377B89A3.8E70F961@ma.usb.ve>...
>I've posted the second iteration of a version of your idea in the binaries
>news. I have to say that it looks
>a little bit strange.


Post a reply to this message

From: Lance Birch
Subject: Re: Creating Spheres of Triangles
Date: 1 Jul 1999 20:59:47
Message: <377c0f03@news.povray.org>
>: I wan't to construct an Sphere out of triangles ,( i know the standard
>: POV-Sphere is faster and better and
>: so on, but i need a trianglesphere ), does anybody know of resources, or
has
>: an tutorial by him self
>: for doing that. it should be possible to say, how complex the sphere
should
>: be, and it should
>: NOT look like an globe, best would be an sphere out of evenly sized
>: triangles.
>
>  Distributing objects evenly on the surface of a sphere is a non-trivial
>task.
>  If making a earth-looking globe (with latitude and longitude lines) is
>enough, that's pretty easy with povray (you need some math, though).

But the triangles won't be the same sizes right?

If you really want to do it perfectly you can use a geosphere with a
geodesic base type of a 20-sided icosahedron.  The facets are all equally
sized equilateral triangles.  From there the sphere can be divided into any
number of segments based on multiples and divisions of the 20 faces.

Right?

Alternatively you could try a polyhedron base type like a tetrahedron or
octahedron (all of which can be made as spacial spherical subdivisions) but
these won't look as even as the icosahedron will.

If you want I can post an example of such an object.

--
Lance.


---
For the latest 3D Studio MAX plug-ins, images and much more, go to:
The Zone - http://come.to/the.zone
For a totally different experience, visit my Chroma Key Website:
Colorblind - http://listen.to/colorblind


Post a reply to this message

Goto Latest 10 Messages Next 10 Messages >>>

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