POV-Ray : Newsgroups : povray.text.tutorials : Rotate around central axis : Re: Rotate around central axis Server Time
18 Apr 2024 19:30:33 EDT (-0400)
  Re: Rotate around central axis  
From: Warp
Date: 20 Dec 2000 07:00:13
Message: <3a409f4d@news.povray.org>
Philippe-H Cadet <del### [at] videotronca> wrote:
: Yes but ObjectCenter. How can I find that if it is not necessary a cube?

  How could povray find it if even you can't find it?
  The center of the object is where you decide it is.

  And no, povray can't calculate a center for the object automatically.
  Why? For many reasons. One of them is that the center of an object may
not be unambiguous.
  Just think about a triangle. What is the center of the triangle? Is it
the average of the vertex points? Is it the intersection of the lines tangent
to the sides of the triangle, going through the center of the side? Is it
the intersection of the middle-angles of the vertex angles? Something else?
  Another reason is that it's not even possible to do it with many objects.
  How do you calculate the center of a julia object? An isosurface? A poly?
What is the center of a plane?

: I thought about translating the global x,y,z axis on the center of the
: object and then after, rotate then translate back the global axis where it
: was before. But the aigain there is no functions that I know to translate
: the global axis.

  I said how to do it, but you didn't believe me:

object
{ MyObject
  translate -ObjectCenter
  rotate whatever
  translate ObjectCenter
}

-- 
main(i,_){for(_?--i,main(i+2,"FhhQHFIJD|FQTITFN]zRFHhhTBFHhhTBFysdB"[i]
):_;i&&_>1;printf("%s",_-70?_&1?"[]":" ":(_=0,"\n")),_/=2);} /*- Warp -*/


Post a reply to this message

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