POV-Ray : Newsgroups : povray.animations : Need help Rotating : Re: Need help Rotating Server Time
1 Jun 2024 08:22:52 EDT (-0400)
  Re: Need help Rotating  
From: Chris B
Date: 28 Jan 2006 16:39:55
Message: <43dbe4ab$1@news.povray.org>
"Charlie" <crr### [at] hotmailcom> wrote in message 
news:web.43dbd7781a56a32b984f60a80@news.povray.org...
>
> Hello, and Thanks ahead of time for any help!!
>
> I'm a chemist and use Povray to render my molecules and it works great.
> I've also made short animations of molecules spinning in space, no 
> problem.
> Now I have hard one that I need help with.  I made a simple structure and
> I manage to define it into pieces. I want piece 1 to remain stationary, 
> but
> I want piece 2 to rotate 180 degrees about and axis.  Sounds easy, but I
> can't define this axis, whenever I rotate the molecule, it always uses the
> origin (where my wanted rotating piece 2 is no where near) and a second
> point that I can define. This generates images of bonds breaking and atoms
> flying off.  Can anyone help??  The povray guides keep talking of vectors
> and I want to define a vector (<X, Y, Z>, <x, y, z>) as my axis to rotate
> around.
>
> Thanks again,
>
> Charlie R.
> Univ of NV, Reno
>
>

In transforms.inc there's an Axis_Rotate_Trans macro.
You should be able to translate your object (the piece you want to rotate) 
to the origin, rotate it around the axis of your choice then translate it 
back.

Regards,
Chris B.


Post a reply to this message

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