POV-Ray : Newsgroups : povray.newusers : rotation vectors ?? Server Time
5 Nov 2024 11:17:13 EST (-0500)
  rotation vectors ?? (Message 1 to 4 of 4)  
From: MR
Subject: rotation vectors ??
Date: 4 Aug 1999 15:44:36
Message: <37a89824@news.povray.org>
hello,

how does a rotation vector work?  i have no problem with
a simple degree rotation around an axis, such as:

box { <0,0,0>, <1,1,1> rotate y*180}

thats a half-circle rotation around the y axis... but what is
this:

box { <0,0,0>,<1,1,1> rotate <0,1,0> }

i tried various values, and i couldn't get a good feel for what
it does... it doesn't appear to be a simple rotation around
the y axis in radians....  i substituted pi for the 1 and didn't
get a 180 degree rotation.

thanks, miker


Post a reply to this message

From: Ken
Subject: Re: rotation vectors ??
Date: 4 Aug 1999 15:58:20
Message: <37A89A9D.D23576B2@pacbell.net>
MR wrote:
> 
> hello,
> 
> how does a rotation vector work?  i have no problem with
> a simple degree rotation around an axis, such as:
> 
> box { <0,0,0>, <1,1,1> rotate y*180}
> 
> thats a half-circle rotation around the y axis... but what is
> this:
> 
> box { <0,0,0>,<1,1,1> rotate <0,1,0> }
> 
> i tried various values, and i couldn't get a good feel for what
> it does... it doesn't appear to be a simple rotation around
> the y axis in radians....  i substituted pi for the 1 and didn't
> get a 180 degree rotation.
> 
> thanks, miker

Rotate y*180 is simply short hand for rotate <0,180,0>. The rotations are taken
by order of xyz so if you specified rotate < 90, -45, 0> then pov would evaluate
this as rotate first +90 degrees around x-axis then -45 degrees around the y-axis.
You can also multiply rotation vectors like: rotate <0,90,0>*2 is equivelant to
rotate y*180. If you rotate by PI by the way you are simply rotating 3.1415
degrees and it would be hardly visible :)

-- 
Ken Tyler
  
mailto://tylereng@pacbell.net
http://home.pacbell.net/tylereng/links.htm


Post a reply to this message

From: Nieminen Mika
Subject: Re: rotation vectors ??
Date: 5 Aug 1999 05:40:56
Message: <37a95c28@news.povray.org>
Note also that if you want to _first_ rotate about the y axis and _then_
about the x axis, you can do it this way:
  rotate <0,45,0> rotate <30,0,0>

-- 
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: Matt Giwer
Subject: Re: rotation vectors ??
Date: 10 Aug 1999 08:21:47
Message: <37B01968.CE971942@giwersworld.org>
MR wrote:

> how does a rotation vector work?  i have no problem with
> a simple degree rotation around an axis, such as:

	The rotation vector is in degrees. They rotate in the order of
appearance, first X then Y then Z. You can have multiple vectors
if you want to rotate them in a different order such as <0,Y,0>
<0,0,Z> <X,0,0> That will rotate in Y Z X order. 

> box { <0,0,0>, <1,1,1> rotate y*180}
> 
> thats a half-circle rotation around the y axis... but what is
> this:
> 
> box { <0,0,0>,<1,1,1> rotate <0,1,0> }

	That is a one degree rotation around Y that you most likely can
not see on the rendering. 

> i tried various values, and i couldn't get a good feel for what
> it does... it doesn't appear to be a simple rotation around
> the y axis in radians....  i substituted pi for the 1 and didn't
> get a 180 degree rotation.

	Since a box is 90 degree symetric, play with 30 and 45 degrees
to see the results. 

-- 
<blink>-------please--don't-----------------</blink>

http://www.giwersworld.org/artii/
http://www.giwersworld.org/artiii/

Finally up on 99/06/22 updated 07/13


Post a reply to this message


Attachments:
Download 'us-ascii' (1 KB)

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