POV-Ray : Newsgroups : povray.newusers : Rotating along XY plane? Server Time
25 Nov 2024 15:45:55 EST (-0500)
  Rotating along XY plane? (Message 1 to 4 of 4)  
From: bardgaijin
Subject: Rotating along XY plane?
Date: 27 Jun 2005 14:25:00
Message: <web.42c044276066220c5c4d7e960@news.povray.org>
I'd like to be able to rotate an object -- for example, hands on a clock --
along a plane (in this case the XY plane). My particular project is not a
clock, but I'm hopful it illustrates my goal.

However, Pov-Ray seems to only be able to rotate objects around a particular
axis.

I guess what I'm looking for is a run-down on the math required -- i.e.
rotate so much along this axis, and then along this axis, etc.

Any help would be greatly appreciated.

Thanks alot.

-Alex


Post a reply to this message

From: Jim Charter
Subject: Re: Rotating along XY plane?
Date: 27 Jun 2005 14:55:07
Message: <42c04b8b$1@news.povray.org>
bardgaijin wrote:
> I'd like to be able to rotate an object -- for example, hands on a clock --
> along a plane (in this case the XY plane). My particular project is not a
> clock, but I'm hopful it illustrates my goal.
> 
> However, Pov-Ray seems to only be able to rotate objects around a particular
> axis.
> 
> I guess what I'm looking for is a run-down on the math required -- i.e.
> rotate so much along this axis, and then along this axis, etc.
> 
> Any help would be greatly appreciated.
> 
> Thanks alot.
> 
> -Alex
> 
> 
Maybe I don't understand your question.

Would neither of these be solutions?

#local I=0;#while(I<12)
         cylinder {
		0,
		<0,1,0>,
		.02
		rotate < I*30, 0, 0 >
		pigment { Blue }
	}
#local I=I+1;#end

#local I=0;#while(I<90)
         cylinder {
		0,
		< 0, sin(I*pi/6), cos(I*pi/6) >,
		.02
		pigment { Red }
	}
#local I=I+1;#end


Post a reply to this message

From: Warp
Subject: Re: Rotating along XY plane?
Date: 27 Jun 2005 14:58:26
Message: <42c04c52@news.povray.org>
bardgaijin <nomail@nomail> wrote:
> I guess what I'm looking for is a run-down on the math required -- i.e.
> rotate so much along this axis, and then along this axis, etc.

  There's a macro called Axis_Rotate_Trans() in transforms.inc which
does exactly this (ie. saves you from figuring out the math :) ).

-- 

                                                          - Warp


Post a reply to this message

From: bancquart sebastien
Subject: Re: Rotating along XY plane?
Date: 9 Jul 2005 07:39:41
Message: <42cfb77d@news.povray.org>
I'm not sure I understand the problem.

Rotating along XY plane doesnt mean rotating around Z axis ?


42c04c52@news.povray.org...
> bardgaijin <nomail@nomail> wrote:
>> I guess what I'm looking for is a run-down on the math required -- i.e.
>> rotate so much along this axis, and then along this axis, etc.
>
>  There's a macro called Axis_Rotate_Trans() in transforms.inc which
> does exactly this (ie. saves you from figuring out the math :) ).
>
> -- 

>                                                          - Warp


Post a reply to this message

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