POV-Ray : Newsgroups : povray.newusers : Local Co-ordinates : Re: Local Co-ordinates Server Time
4 Sep 2024 18:12:44 EDT (-0400)
  Re: Local Co-ordinates  
From: KalleK
Date: 19 Sep 2002 18:37:26
Message: <3d8a51a6$1@news.povray.org>
"insomniac" <lee### [at] hotmailcom> schrieb im Newsbeitrag
news:web.3d8a4bb0ae2b17b330411fcf0@news.povray.org
> Is there a way to change the local co-ordinates of an object or
> grouped objects so that when you rotate that object it moves around
> that point. Like how you can do it in Moray. But when I use the pov.
> scene Moray emits it hasn't converted the co-ordinates.
>
> Thank you,
>           your help will be greatly appreciated.

You have to move your object into the origin, rotate it, and move it back.

Maybe a little macro will do:

#macro Rotate_around (RotVector, Position)
    translate -Position
    rotate RotVector
    translate Position
#end

Maybe such a macro is already in the includes which are shipped with POV-Ray,
but I don't know.

Kalle


Post a reply to this message

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