|
|
|
|
|
|
| |
| |
|
|
|
|
| |
| |
|
|
1) Intersecting cylinders
2) Rotating torii
3) Rotating cylinders (and it's a hyperbola BTW :-p)
And I haven't read any replies yet
--
David Fontaine <dav### [at] faricynet> ICQ 55354965
Please visit my website: http://www.faricy.net/~davidf/
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
This one is cool.
(And this time you'll have to figure out the code yourself):
Post a reply to this message
Attachments:
Download 'image.jpg' (36 KB)
Preview of image 'image.jpg'
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Warp wrote in message <391a8be3@news.povray.org>...
> This one is cool.
> (And this time you'll have to figure out the code yourself):
>
torii, centered just to one side of the centre of that object,
rotated and translated around.
Gail
********************************************************************
* gsh### [at] monotixcoza * Reality.dat not found *
* http://www.rucus.ru.ac.za/~gail/ * Attempting to reboot universe *
********************************************************************
* The best way to accelerate Windows NT is at 9.8 m/s^2 *
********************************************************************
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Warp wrote:
> This one is cool.
Yes.I think so too.
> (And this time you'll have to figure out the code yourself):
It looks familiar. Heres how I did it:
#declare MajR = 5;
#declare MinR = 1.5;
#declare SmallTorus = torus { MajR, 0.25 }
#declare TVector = MajR*y + MinR*z;
#declare TVector = TVector - 2.5*y; // Remove this line to get a proper torus
#declare TiltedTorus = vtilt(SmallTorus, TVector)
object {
CircleSpread(TiltedTorus, MinR, 24)
pigment { color Green }
}
(See below for the rest of my code.)
Tor Olav
--
mailto:tor### [at] hotmailcom
http://www.crosswinds.net/~tok/tokrays.html
#macro VectorAngles(Vector)
<acos(vnormalize((x+z)*Vector).x)*(Vector.z < 0 ? -1 : 1),
acos(vnormalize(Vector).y),
0>
#end // macro VectorAngles
#macro vtilt(Thing, TVector)
#local RotateAngles = VectorAngles(TVector);
object {
Thing
rotate degrees(RotateAngles.x)*y
rotate -degrees(RotateAngles.y)*z
rotate -degrees(RotateAngles.x)*y
}
#end // macro vtilt
#macro CircleSpread(Thing, Radius, Nr)
#local deg = 360/Nr;
#local MaxCnt = int(Nr);
#local Cnt = 0;
merge {
#while (Cnt < MaxCnt)
object {
Thing
translate Radius*x
rotate Cnt*deg*y
}
#local Cnt = Cnt + 1;
#end // while
}
#end // macro CircleSpread
// ====================================================
#declare MajR = 5;
#declare MinR = 1.5;
#declare SmallTorus = torus { MajR, 0.25 }
#declare TVector = MajR*y + MinR*z;
#declare TVector = TVector - 2.5*y; // Remove this line to get a proper torus
#declare TiltedTprus = vtilt(SmallTorus, TVector)
object {
CircleSpread(TiltedTprus, MinR, 24)
pigment { color Green }
}
/*
torus {
MajR, MinR
pigment { color Red }
}
*/
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Actually it's a bit simpler:
union
{ #declare Angle=0;
#while(Angle<360)
torus { 1,.04 rotate z*30 translate z*.25 rotate y*Angle }
#declare Angle=Angle+15;
#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
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Warp wrote:
> Actually it's a bit simpler:
>
> union
> { #declare Angle=0;
> #while(Angle<360)
> torus { 1,.04 rotate z*30 translate z*.25 rotate y*Angle }
> #declare Angle=Angle+15;
> #end
> }
I knew that it could be done that way.
But I did it my way! =)
Since I'm lazy when it comes to laborious math calculations,
I first defined the important parameters and then let the
macros (which I already had) do the calculations.
And btw:
How would you for instance calculate the dimensions of the
bounded_by shapes if you where to model shapes like the one
I posted in TorusClutter?
For that TorusCluster it was just:
bounded_by { torus { MajR, MinR1 + MinR2 } }
for the "first" level and
bounded_by { torus { MajR, MinR1 + MinR2 + MinR3 } }
for the "second" level
Tor Olav
--
mailto:tor### [at] hotmailcom
http://www.crosswinds.net/~tok/tokrays.html
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |
| |
|
|
Warp wrote:
>
> Actually it's a bit simpler:
>
> union
> { #declare Angle=0;
> #while(Angle<360)
> torus { 1,.04 rotate z*30 translate z*.25 rotate y*Angle }
> #declare Angle=Angle+15;
> #end
> }
Slightly simpler: change the relevant line to
torus { 1, 0.04 translate x*0.25 rotate <30,Angle,0> }
--
Anton Sherwood -- br0### [at] p0b0xcom -- http://ogre.nu/
Post a reply to this message
|
|
| |
| |
|
|
|
|
| |