POV-Ray : Newsgroups : povray.binaries.images : More Fun with Mosaics (WIP) : Re: More Fun with Mosaics (WIP) Server Time
13 Aug 2024 23:25:08 EDT (-0400)
  Re: More Fun with Mosaics (WIP)  
From: George Pantazopoulos
Date: 6 Jan 2003 13:14:13
Message: <3e19c775@news.povray.org>
Hey Aaron,

    What if you used the spherical coordinates ( rho, phi, theta ) in a
nested loop? Theta is the angle corresponding to the floor of the dome. Phi
is the other angle, a *quarter-circle* going from the tip of the ceiling to
the
floor. It shouldnt matter if you increment phi or theta in your inner loop,
you'd just use the remaining one as the outer loop and increment it there.

    Theta would go from [0 to 2PI] and phi would go from [0 to PI/2], and
rho would be a constant (the radius of the dome). You would use a timestep t
and place a tile at every timestep in your inner loop (as well as increment
the angles). To actually place the tile, you would convert from spherical to
rectangular coords as follows:

x = rho sin (phi) cos ( theta )
y = rho sin (phi) sin ( theta )
z = rho cos (phi)

Just an idea, this would elegantly accomplish what you did in a loop.. I
just took Calculus 3, and this is basically how we integrate a multivariable
function in spherical coordinates.

Regards,
George Pantazopoulos





"Aaron Gillies" <no### [at] spamcom> wrote in message
news:3E1### [at] spamcom...
> It's a bit complicated to explain, and my code is so
> terrible that I don't dare post it.  Briefly, I thought
> of the problem as lining the interior of a dome with
> rows of tiles.  So, I used trigonometry to calculate
> the X and Y position of one endpoint of each row and
> then rotated the tiles around the Y axis.  The number of
> tiles in each row was calculated by taking the
> circumference of the circle defined by the end points
> and dividing it by the size of the tile.  I then
> rotated each tile to the proper angle.  Seems like
> a lot of work for just this effect and I wonder if
> there is not an easier way ...
>
> Aaron
>
> Aaron Gillies
> New York City
> x3rxes[^]yahoo.com
>
>
> George Pantazopoulos wrote:
> > Thats pretty amazing Aaron, how do you get tiles to line an arbitrary
> > surface like that? And with a pattern no less?
> >
> > George
>


Post a reply to this message

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