POV-Ray : Newsgroups : povray.newusers : Turn a torus Server Time
11 Oct 2026 12:19:07 EDT (-0400)
  Turn a torus (Message 1 to 19 of 19)  
From: Oleguer Vilella
Subject: Turn a torus
Date: 25 Sep 2004 12:27:45
Message: <41559c81@news.povray.org>
Hello,

I'm traying to turn this torus like a bridge, but the code that I used
doesn't work right. What's the problem?
====================================
difference {
torus { .3, .1 } plane { z, 0 rotate y*90} texture { T_Gold_1D } finish {
specular 1 ambient 0.9 reflection .001 phong 0.3 phong_size 30 }
scale 0.7 scale <1.5, 1, 9> translate <3, 2, 0> rotate <90, 180, 0>
translate y*2*sin(1*2/1*9*pi)*cos(1*0.5/0.9*2*pi)}
 ====================================
I tray it with the translate "y*2*sin(1*2/1*9*pi)*cos(1*0.5/0.9*2*pi)"

Thanks in advance,
Oleguer
http://www.infonegocio.com/oleguervm


Post a reply to this message

From: Warp
Subject: Re: Turn a torus
Date: 27 Sep 2004 09:45:07
Message: <41581962@news.povray.org>
Oleguer Vilella <ole### [at] infonegociocom> wrote:
> I'm traying to turn this torus like a bridge, but the code that I used
> doesn't work right. What's the problem?

  You should be more specific about what you are trying to do. That
description is not clear enough to know.

-- 
#macro N(D)#if(D>99)cylinder{M()#local D=div(D,104);M().5,2pigment{rgb M()}}
N(D)#end#end#macro M()<mod(D,13)-6mod(div(D,13)8)-3,10>#end blob{
N(11117333955)N(4254934330)N(3900569407)N(7382340)N(3358)N(970)}//  - Warp -


Post a reply to this message

From: Oleguer Vilella
Subject: Re: Turn a torus
Date: 27 Sep 2004 10:50:57
Message: <415828d1@news.povray.org>
Well I want to turn the torus like a bridge. In the middle of it. I'm
thinking how can I do it...
Warp, can you tell me where are you from? I put on my web page the people
who are helpping me to make the pictures. What's the right verb: make or do?

Thanks,
Oleguer

"Warp" <war### [at] tagpovrayorg> escribió en el mensaje
news:41581962@news.povray.org...
> Oleguer Vilella <ole### [at] infonegociocom> wrote:
> > I'm traying to turn this torus like a bridge, but the code that I used
> > doesn't work right. What's the problem?
>
>   You should be more specific about what you are trying to do. That
> description is not clear enough to know.
>
> -- 
> #macro N(D)#if(D>99)cylinder{M()#local D=div(D,104);M().5,2pigment{rgb
M()}}
> N(D)#end#end#macro M()<mod(D,13)-6mod(div(D,13)8)-3,10>#end blob{
> N(11117333955)N(4254934330)N(3900569407)N(7382340)N(3358)N(970)}//  -
Warp -


Post a reply to this message

From: Warp
Subject: Re: Turn a torus
Date: 27 Sep 2004 11:02:02
Message: <41582b6a@news.povray.org>
Oleguer Vilella <ole### [at] infonegociocom> wrote:
> Well I want to turn the torus like a bridge. In the middle of it.

  Sorry, I might be unusually obtuse today, but I still don't understand
what you mean...

-- 
#macro M(A,N,D,L)plane{-z,-9pigment{mandel L*9translate N color_map{[0rgb x]
[1rgb 9]}scale<D,D*3D>*1e3}rotate y*A*8}#end M(-3<1.206434.28623>70,7)M(
-1<.7438.1795>1,20)M(1<.77595.13699>30,20)M(3<.75923.07145>80,99)// - Warp -


Post a reply to this message

From: Oleguer Vilella
Subject: Re: Turn a torus
Date: 27 Sep 2004 11:11:33
Message: <41582da5$1@news.povray.org>
Well, I'm sorry, maybe is my English...
I want to double the torus. I want make an angle in the middle of the torus
like a bridge. For exemple: if the torus has 4cm I want to make an angle of
45º in the middle of it (2 cm).
Can you tell me where are you from please? In that way I can put you in my
web page on the gratitudes. I like to put all the people who are helpping me
to do the pictures.

"Warp" <war### [at] tagpovrayorg> escribió en el mensaje
news:41582b6a@news.povray.org...
> Oleguer Vilella <ole### [at] infonegociocom> wrote:
> > Well I want to turn the torus like a bridge. In the middle of it.
>
>   Sorry, I might be unusually obtuse today, but I still don't understand
> what you mean...
>
> -- 
> #macro M(A,N,D,L)plane{-z,-9pigment{mandel L*9translate N color_map{[0rgb
x]
> [1rgb 9]}scale<D,D*3D>*1e3}rotate y*A*8}#end M(-3<1.206434.28623>70,7)M(
> -1<.7438.1795>1,20)M(1<.77595.13699>30,20)M(3<.75923.07145>80,99)// -
Warp -


Post a reply to this message

From: Oleguer Vilella
Subject: Re: Turn a torus
Date: 27 Sep 2004 15:00:37
Message: <41586355@news.povray.org>
I think that I have to do a macro...
I trayed with it:
======================================
#local YPos = y*9*sin(1*4/5*9*pi)*cos(1*0.5/6*2*pi);
#local XPos = (1+2*2);
#local ZPos = (1+0.5*1);
======================================
I'm going to do a macro.


"Oleguer Vilella" <ole### [at] infonegociocom> escribió en el mensaje
news:41582da5$1@news.povray.org...
> Well, I'm sorry, maybe is my English...
> I want to double the torus. I want make an angle in the middle of the
torus
> like a bridge. For exemple: if the torus has 4cm I want to make an angle
of
> 45º in the middle of it (2 cm).
> Can you tell me where are you from please? In that way I can put you in my
> web page on the gratitudes. I like to put all the people who are helpping
me
> to do the pictures.
>
> "Warp" <war### [at] tagpovrayorg> escribió en el mensaje
> news:41582b6a@news.povray.org...
> > Oleguer Vilella <ole### [at] infonegociocom> wrote:
> > > Well I want to turn the torus like a bridge. In the middle of it.
> >
> >   Sorry, I might be unusually obtuse today, but I still don't understand
> > what you mean...
> >
> > -- 
> > #macro M(A,N,D,L)plane{-z,-9pigment{mandel L*9translate N
color_map{[0rgb
> x]
> > [1rgb 9]}scale<D,D*3D>*1e3}rotate y*A*8}#end M(-3<1.206434.28623>70,7)M(
> > -1<.7438.1795>1,20)M(1<.77595.13699>30,20)M(3<.75923.07145>80,99)// -
> Warp -
>
>


Post a reply to this message

From: Oleguer Vilella
Subject: Re: Turn a torus
Date: 27 Sep 2004 15:46:13
Message: <41586e05@news.povray.org>
Well... It isn't correct. I'm thinking...
=============================
difference {
torus { .3, .1 } plane { z, 0 rotate y*90} texture { T_Gold_1D } finish {
specular 1 ambient 0.9 reflection .001 phong 0.3 phong_size 30 }
scale 0.7 scale <1.5, 1, 9> translate <3, 2, 0> rotate <90, 180, 0>
#macro MakeMany (Stuff, amplitude)
#while (4 < 6 )
#local YPos = amplitude*sin(1*4/5*9*pi)*cos(1*0.5/6*2*pi);
#local XPos = (1+2*2);
#local ZPos = (1+0.5*1);
object {
         Stuff
         translate <xPos, yPos, zPos>
         rotate 29*x
       }
#local 0.5 = 0.5 + 1;
#end
#local 4 = 4 + 1;
#end
}
#declare amplitude = 40;
==================================








"Oleguer Vilella" <ole### [at] infonegociocom> escribió en el mensaje
news:41586355@news.povray.org...
> I think that I have to do a macro...
> I trayed with it:
> ======================================
> #local YPos = y*9*sin(1*4/5*9*pi)*cos(1*0.5/6*2*pi);
> #local XPos = (1+2*2);
> #local ZPos = (1+0.5*1);
> ======================================
> I'm going to do a macro.
>
>
> "Oleguer Vilella" <ole### [at] infonegociocom> escribió en el mensaje
> news:41582da5$1@news.povray.org...
> > Well, I'm sorry, maybe is my English...
> > I want to double the torus. I want make an angle in the middle of the
> torus
> > like a bridge. For exemple: if the torus has 4cm I want to make an angle
> of
> > 45º in the middle of it (2 cm).
> > Can you tell me where are you from please? In that way I can put you in
my
> > web page on the gratitudes. I like to put all the people who are
helpping
> me
> > to do the pictures.
> >
> > "Warp" <war### [at] tagpovrayorg> escribió en el mensaje
> > news:41582b6a@news.povray.org...
> > > Oleguer Vilella <ole### [at] infonegociocom> wrote:
> > > > Well I want to turn the torus like a bridge. In the middle of it.
> > >
> > >   Sorry, I might be unusually obtuse today, but I still don't
understand
> > > what you mean...
> > >
> > > -- 
> > > #macro M(A,N,D,L)plane{-z,-9pigment{mandel L*9translate N
> color_map{[0rgb
> > x]
> > > [1rgb 9]}scale<D,D*3D>*1e3}rotate y*A*8}#end
M(-3<1.206434.28623>70,7)M(
> > > -1<.7438.1795>1,20)M(1<.77595.13699>30,20)M(3<.75923.07145>80,99)// -
> > Warp -
> >
> >
>
>


Post a reply to this message

From: Christopher James Huff
Subject: Re: Turn a torus
Date: 27 Sep 2004 17:19:46
Message: <cjameshuff-759B38.17200427092004@news.povray.org>
In article <41586355@news.povray.org>,
 "Oleguer Vilella" <ole### [at] infonegociocom> wrote:

> I think that I have to do a macro...
> I trayed with it:
> ======================================
> #local YPos = y*9*sin(1*4/5*9*pi)*cos(1*0.5/6*2*pi);
> #local XPos = (1+2*2);
> #local ZPos = (1+0.5*1);
> ======================================
> I'm going to do a macro.

I have absolutely no idea what you're doing with this. It is certainly 
making the problem far more difficult than it needs to be. (For example, 
your XPos is just 5, and ZPos 1.5. I haven't a clue what YPos is 
supposed to be.)

Are you trying to fold a torus? What kind of bridge is it supposed to be 
like? What part has a 45 degree angle? Is 4cm a minor or major radius, 
or something else? What about the middle of it?

You need to give more information about what you want. Repeating the 
same vague description and apparently random bits of code won't work, no 
matter how good your English is.

-- 
Christopher James Huff <cja### [at] earthlinknet>
http://home.earthlink.net/~cjameshuff/
POV-Ray TAG: <chr### [at] tagpovrayorg>
http://tag.povray.org/


Post a reply to this message

From: Oleguer Vilella
Subject: Re: Turn a torus
Date: 28 Sep 2004 02:31:22
Message: <4159053a@news.povray.org>
Ok Christpher,

Well, I want to double or fold (I think the verbs are corrects) this torus
in the middle of it to make an angle of 45º.
The idea is like a bridge, the bridges make an angle in the middle of it of
for exemple 50º.
Maybe now is more clear...

Thank you very much,
Oleguer








"Christopher James Huff" <cja### [at] earthlinknet> escribió en el mensaje
news:cjameshuff-759B38.17200427092004@news.povray.org...
> In article <41586355@news.povray.org>,
>  "Oleguer Vilella" <ole### [at] infonegociocom> wrote:
>
> > I think that I have to do a macro...
> > I trayed with it:
> > ======================================
> > #local YPos = y*9*sin(1*4/5*9*pi)*cos(1*0.5/6*2*pi);
> > #local XPos = (1+2*2);
> > #local ZPos = (1+0.5*1);
> > ======================================
> > I'm going to do a macro.
>
> I have absolutely no idea what you're doing with this. It is certainly
> making the problem far more difficult than it needs to be. (For example,
> your XPos is just 5, and ZPos 1.5. I haven't a clue what YPos is
> supposed to be.)
>
> Are you trying to fold a torus? What kind of bridge is it supposed to be
> like? What part has a 45 degree angle? Is 4cm a minor or major radius,
> or something else? What about the middle of it?
>
> You need to give more information about what you want. Repeating the
> same vague description and apparently random bits of code won't work, no
> matter how good your English is.
>
> -- 
> Christopher James Huff <cja### [at] earthlinknet>
> http://home.earthlink.net/~cjameshuff/
> POV-Ray TAG: <chr### [at] tagpovrayorg>
> http://tag.povray.org/


Post a reply to this message

From: ingo
Subject: Re: Turn a torus
Date: 28 Sep 2004 04:16:29
Message: <Xns95726884FCF83seed7@news.povray.org>
in news:4159053a@news.povray.org Oleguer Vilella wrote:

> Maybe now is more clear...
> 

Could you make a drawing and post it to the images group?

Ingo


Post a reply to this message

From: Oleguer Vilella
Subject: Re: Turn a torus
Date: 28 Sep 2004 10:52:40
Message: <41597ab8$1@news.povray.org>
Yes, of course.



"ingo" <ing### [at] tagpovrayorg> escribió en el mensaje
news:Xns95726884FCF83seed7@news.povray.org...
> in news:4159053a@news.povray.org Oleguer Vilella wrote:
>
> > Maybe now is more clear...
> >
>
> Could you make a drawing and post it to the images group?
>
> Ingo


Post a reply to this message

From: JWV
Subject: Re: Turn a torus
Date: 28 Sep 2004 12:19:15
Message: <41598f03$1@news.povray.org>
I assume you have drawn 2 views of the torus, one has some perspective, and
one is without perspective (am i wrong?). But still, i don't see what you
want to do.

You are clearly basing you model on a real life bridge (across water?), so
could you find a picture on the internet which shows the type of bridge you
are after?

Greetings,

JWV

"Oleguer Vilella" <ole### [at] infonegociocom> wrote in message
news:41597ab8$1@news.povray.org...
> Yes, of course.
>
>
>
> "ingo" <ing### [at] tagpovrayorg> escribió en el mensaje
> news:Xns95726884FCF83seed7@news.povray.org...
> > in news:4159053a@news.povray.org Oleguer Vilella wrote:
> >
> > > Maybe now is more clear...
> > >
> >
> > Could you make a drawing and post it to the images group?
> >
> > Ingo
>
>


Post a reply to this message

From: Oleguer Vilella
Subject: Re: Turn a torus
Date: 28 Sep 2004 12:36:28
Message: <4159930c$1@news.povray.org>
The two first pictures are the torus, te first one is like appears on the
POV-Ray without modifications, and the second one I with an angle.
The pictures that are above of the torus, one is a stright line and the
other is the same line with an angle.
I want to do the same with the torus: I have it straight an I want to do an
angle in the middle of it. Just like with the straight line that it converts
like a bridge doing an angle in the middle of it.
I think it's easy to do.


"JWV" <jwv|at|planet.nl> escribió en el mensaje
news:41598f03$1@news.povray.org...
> I assume you have drawn 2 views of the torus, one has some perspective,
and
> one is without perspective (am i wrong?). But still, i don't see what you
> want to do.
>
> You are clearly basing you model on a real life bridge (across water?), so
> could you find a picture on the internet which shows the type of bridge
you
> are after?
>
> Greetings,
>
> JWV
>
> "Oleguer Vilella" <ole### [at] infonegociocom> wrote in message
> news:41597ab8$1@news.povray.org...
> > Yes, of course.
> >
> >
> >
> > "ingo" <ing### [at] tagpovrayorg> escribió en el mensaje
> > news:Xns95726884FCF83seed7@news.povray.org...
> > > in news:4159053a@news.povray.org Oleguer Vilella wrote:
> > >
> > > > Maybe now is more clear...
> > > >
> > >
> > > Could you make a drawing and post it to the images group?
> > >
> > > Ingo
> >
> >
>
>


Post a reply to this message

From: Chris B
Subject: Re: Turn a torus
Date: 28 Sep 2004 12:53:31
Message: <4159970b@news.povray.org>
"Oleguer Vilella" <ole### [at] infonegociocom> wrote in message
news:41597ab8$1@news.povray.org...
> Yes, of course.
>
>
>
> "ingo" <ing### [at] tagpovrayorg> escribió en el mensaje
> news:Xns95726884FCF83seed7@news.povray.org...
> > in news:4159053a@news.povray.org Oleguer Vilella wrote:
> >
> > > Maybe now is more clear...
> > >
> >
> > Could you make a drawing and post it to the images group?
> >
> > Ingo
>
>

Hi Oleguer,

Your original object cut a torus in two, scaled it (non uniformly) then
rotated it and translated it.

Your drawing ("My Torus - Straight") seems to be scaled uniformly, and cut
differently. Your second drawing ("An angle") seems to me to be the same
shape rotated about 45 degrees towards the camera so the middle looks fatter
because it's closer to the camera.

If that is what you want, then this scene should do it for you:

camera {
  location  <0.0, 0, -0.8>
  look_at   <0.0, 0.0,  0.0>
}

light_source { 0 color rgb 1
  translate <-30, 30, -30>
}


#declare myBridge = difference {
  // Create a torus and move it left of the origin
  torus { .3, .04  translate -x*0.1}
  // Cut away using a vertical plane rotated by
  // 25 degrees around vertical axis
  plane { x, 0 rotate y*25}
  // Cut away using a second plane rotated by -25
  // degrees around the vertical axis
  plane { x, 0 rotate -y*25}
  pigment {color rgb <1,0,0>}
}

object {myBridge rotate <-90,180,0> }
object {myBridge rotate <-90,135,0> translate x*0.25}


Good luck.


Post a reply to this message

From: ingo
Subject: Re: Turn a torus
Date: 28 Sep 2004 12:54:57
Message: <Xns9572C06BC5F19seed7@news.povray.org>
in news:4159930c$1@news.povray.org Oleguer Vilella wrote:

> The pictures that are above of the torus, one is a stright line and the
> other is the same line with an angle.
> 

Sorry Oleguer, but it still is not 100% clear to me what it is you want.

Is it the following: I have a torus that lays flat on a table, now I pick 
one end up and bend it up?  If this, or something simmilar is the case, 
then you cant do it with a torus in POV-Ray as non uniform deformations 
are not supported.

What you can use though is the spheresweep object. You just have to define 
the shape as a spline.


Ingo


Post a reply to this message

From: Oleguer Vilella
Subject: Re: Turn a torus
Date: 28 Sep 2004 13:55:29
Message: <4159a591@news.povray.org>
I did an other render and I put it on the binaries.images, I think it can
helps.
I want to do it with the torus, my torus is straight and I want to make an
angle, like on my render.
Tor Olav helpped me to do a render looks like it.


"Chris B" <c_b### [at] btconnectcom> escribió en el mensaje
news:4159970b@news.povray.org...
>
> "Oleguer Vilella" <ole### [at] infonegociocom> wrote in message
> news:41597ab8$1@news.povray.org...
> > Yes, of course.
> >
> >
> >
> > "ingo" <ing### [at] tagpovrayorg> escribió en el mensaje
> > news:Xns95726884FCF83seed7@news.povray.org...
> > > in news:4159053a@news.povray.org Oleguer Vilella wrote:
> > >
> > > > Maybe now is more clear...
> > > >
> > >
> > > Could you make a drawing and post it to the images group?
> > >
> > > Ingo
> >
> >
>
> Hi Oleguer,
>
> Your original object cut a torus in two, scaled it (non uniformly) then
> rotated it and translated it.
>
> Your drawing ("My Torus - Straight") seems to be scaled uniformly, and cut
> differently. Your second drawing ("An angle") seems to me to be the same
> shape rotated about 45 degrees towards the camera so the middle looks
fatter
> because it's closer to the camera.
>
> If that is what you want, then this scene should do it for you:
>
> camera {
>   location  <0.0, 0, -0.8>
>   look_at   <0.0, 0.0,  0.0>
> }
>
> light_source { 0 color rgb 1
>   translate <-30, 30, -30>
> }
>
>
> #declare myBridge = difference {
>   // Create a torus and move it left of the origin
>   torus { .3, .04  translate -x*0.1}
>   // Cut away using a vertical plane rotated by
>   // 25 degrees around vertical axis
>   plane { x, 0 rotate y*25}
>   // Cut away using a second plane rotated by -25
>   // degrees around the vertical axis
>   plane { x, 0 rotate -y*25}
>   pigment {color rgb <1,0,0>}
> }
>
> object {myBridge rotate <-90,180,0> }
> object {myBridge rotate <-90,135,0> translate x*0.25}
>
>
> Good luck.
>
>
>


Post a reply to this message

From: B  Gimeno
Subject: RE: Turn a torus
Date: 28 Sep 2004 13:57:47
Message: <4159a61b@news.povray.org>
I'm sorry for all you who hate international postings here, but I think it's
the only way

Eh! Oleguer! Si no te aclaras con el inglés tienes un grupo internacional
para postear en español sin necesidad de calentarte tanto la cabeza, ni de
calentarsela a los demás. Y por cierto, también me gustaría una respuesta
tuya a mi mensaje sobre los derechos de Autor, que por si no lo habías
captado iba referido a tí.

thanks
B. Gimeno


Post a reply to this message

From: Oleguer Vilella
Subject: Re: Turn a torus
Date: 28 Sep 2004 14:15:23
Message: <4159aa3b$1@news.povray.org>
Yes, no problem.
Please, give me an e-mail adress to replay your message,
nos### [at] jazzfreecom, doesn't work.
Or if you want, you can sent me an e-mail on my e-mail adress and then I
will replay it.

Thank you,
Oleguer


"B. Gimeno" <nos### [at] jazzfreecom> escribió en el mensaje
news:4159a61b@news.povray.org...
> I'm sorry for all you who hate international postings here, but I think
it's
> the only way
>
> Eh! Oleguer! Si no te aclaras con el inglés tienes un grupo internacional
> para postear en español sin necesidad de calentarte tanto la cabeza, ni de
> calentarsela a los demás. Y por cierto, también me gustaría una respuesta
> tuya a mi mensaje sobre los derechos de Autor, que por si no lo habías
> captado iba referido a tí.
>
> thanks
> B. Gimeno
>
>


Post a reply to this message

From: Mike Williams
Subject: Re: Turn a torus
Date: 28 Sep 2004 15:26:59
Message: <bN1aNDAxnbWBFwcC@econym.demon.co.uk>
Wasn't it Oleguer Vilella who wrote:
>Well, I'm sorry, maybe is my English...
>I want to double the torus. I want make an angle in the middle of the torus
>like a bridge. For exemple: if the torus has 4cm I want to make an angle of
>45º in the middle of it (2 cm).

Are either of these anything like what you are after? Change the "Bend"
and "Sharpness" parameters as necessary.

//-----------------------------------------------------------------

#include "functions.inc"

camera { location  <-0, 1, -4> look_at <0, 0, 0> angle 29}
background {rgb 1}

light_source {<-100,200,-100> colour rgb 1}

#declare Bend=0.6;
#declare Sharpness=1.7;

isosurface {
  function { f_torus(x,y+pow(abs(x),Sharpness)*Bend,z,0.8,0.15) }
        max_gradient 1.5
        contained_by{sphere {0,1.2}}
        pigment {rgb .9}
}

//-----------------------------------------------------------------

#include "functions.inc"

camera { location  <-0, 1, -4> look_at <0, 0, 0> angle 40}
background {rgb 1}

light_source {<-100,200,-100> colour rgb 1}

#declare Bend=0.4;
#declare Sharpness=1.7;

isosurface {
  function { f_torus(y+pow(abs(x),Sharpness)*Bend,z,x,0.8,0.15) }
        max_gradient 1.5
        contained_by{sphere {0,1.2}}
        pigment {rgb .9}
}

//------------------------------------------------------------------

Although it's nothing to do with your question, here's the same thing
with some different values of Bend and Sharpness and a slightly larger
contained_by sphere.

#include "functions.inc"

camera { location  <-0, 1, -4> look_at <0, 0.1, 0> angle 40}
background {rgb 1}

light_source {<-100,200,-100> colour rgb 1}

#declare Bend=-0.5;
#declare Sharpness=0.8;

isosurface {
  function { f_torus(y+pow(abs(x),Sharpness)*Bend,z,x,0.8,0.15) }
        max_gradient 1.5
        contained_by{sphere {0,1.5}}
        pigment {rgb x}
}


Post a reply to this message

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