POV-Ray : Newsgroups : povray.newusers : Looking for info on vaxis_rotate( ) or related functions : Re: Looking for info on vaxis_rotate( ) or related functions Server Time
4 Nov 2024 17:29:14 EST (-0500)
  Re: Looking for info on vaxis_rotate( ) or related functions  
From: Will W
Date: 28 Feb 2003 13:46:50
Message: <3e5fae9a@news.povray.org>
Thanks for this pointer! I haven't looked at any of the transforms.inc
material yet.

 I had thought that in scanning the manual's section on functions that
return point vectors, I had done a comprehensive search of everything that
might be of use in this situation. I hadn't realized that I was skipping
right by all the wealth that is kept in macros-- silly me.

So documentation on functions is organized by return type, which is nice.
But documentation on macros included in the v3.5 package are organized by...
the arbitrary name of the include file? I hope that doesn't sound snide. I
really appreciate all the effort that has gone into making POVRay and
documenting it. But I think I'm detecting an opportunity for improvement.


--
Will Woodhull
Thornhenge, SW Oregon, USA
willl.at.thornhenge.net


"Tom Melly" <tom### [at] tomandlucouk> wrote in message
news:3e5f32c8@news.povray.org...
>
> "Will W" <wil### [at] NOSPAMwizzardsnet> wrote in message
> news:3e5e7330@news.povray.org...
> > I have a situation where I am defining a set of points relative to
<0,0,0>
> > then rotating them into the final position. In a later step, I need to
know
> > where one of these points has ended up (so I can use it with the
"Connect"
> > macro).
> >
>
> <snip>
>
> As far as I understand it, I think you need the 'vtransform' function from
> 'transforms.inc'.
>
> Here is a sample scene that returns the new position to the #debug stream:
>
> #declare S1= sphere{0,0.1 pigment{rgb 1}}
> #declare T1= <2,0,0>;
> #declare R1= <0,-45,0>;
>
> object{S1 translate T1 rotate R1}
>
> #include "transforms.inc"
> #declare NewPos = vtransform(T1, transform{rotate R1});
>
> #debug concat("New Pos: ", vstr(3, NewPos, ",", 0, 5), "\n")
>
>


Post a reply to this message

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