POV-Ray : Newsgroups : povray.advanced-users : rotating around x-axis inside povray Server Time
29 Jul 2024 16:19:17 EDT (-0400)
  rotating around x-axis inside povray (Message 1 to 10 of 10)  
From: Remco Poelstra
Subject: rotating around x-axis inside povray
Date: 26 Feb 2001 13:31:52
Message: <3A9AA182.3090402@home.nl>
Hi,

How does povray rotate around the x-axis?
This way:
<0,1,0>*< 1,  0,  0,
0,  C,  S,
0, -S,  C>

Or this way:

< 1,  0,  0,	*< 0
0,  C,  S,	   1
0, -S,  C> 0>


Of course I cutted out the fourth row.

Thanks in advance,

Remco Poelstra


Post a reply to this message

From: Vahur Krouverk
Subject: Re: rotating around x-axis inside povray
Date: 26 Feb 2001 14:08:52
Message: <3A9AA9D9.F47E26D0@aetec.ee>
Remco Poelstra wrote:
> 
> Hi,
> 
> How does povray rotate around the x-axis?
> This way:
> <0,1,0>*< 1,  0,  0,
> 0,  C,  S,
> 0, -S,  C>
> 
> Or this way:
> 
> < 1,  0,  0,    *< 0
> 0,  C,  S,         1
> 0, -S,  C> 0>
> 
> Of course I cutted out the fourth row.
> 

Deciding from matrices.c POVRay multiplies vector row with matrix. But
why is it important?


Post a reply to this message

From: Remco Poelstra
Subject: Re: rotating around x-axis inside povray
Date: 26 Feb 2001 15:32:30
Message: <3A9ABDC9.70904@home.nl>
Vahur Krouverk wrote:
 >

> Deciding from matrices.c POVRay multiplies vector row with matrix. But
> why is it important?

Because I'm writing a program that does some matrix calculations and 
outputs to povray.
Now I was wondering how the matrices on
http://enphilistor.users4.50megs.com/matrix.htm
are constructed. I redesigned them by hand, and came out by the same 
matrices, except that I use the second method to multiply. ie, the 
vector as a column, not a row.

Remco Poelstra


Post a reply to this message

From: Josh English
Subject: Re: rotating around x-axis inside povray
Date: 26 Feb 2001 16:31:06
Message: <3A9ACB70.FAF52A5@spiritone.com>
It's the difference between multiplying the vector to the right or left. I
believe a 1by4 vector is multiplied to the right by the 4 by 4 matrix in
POV-Ray

Josh

Remco Poelstra wrote:

> Vahur Krouverk wrote:
>  >
>
> > Deciding from matrices.c POVRay multiplies vector row with matrix. But
> > why is it important?
>
> Because I'm writing a program that does some matrix calculations and
> outputs to povray.
> Now I was wondering how the matrices on
> http://enphilistor.users4.50megs.com/matrix.htm
> are constructed. I redesigned them by hand, and came out by the same
> matrices, except that I use the second method to multiply. ie, the
> vector as a column, not a row.
>
> Remco Poelstra

--
Josh English -- Lexiphanic Lethomaniac
eng### [at] spiritonecom
The POV-Ray Cyclopedia http://www.spiritone.com/~english/cyclopedia/
"He who hebetates is last."


Post a reply to this message

From: Vahur Krouverk
Subject: Re: rotating around x-axis inside povray
Date: 27 Feb 2001 05:18:39
Message: <3A9B7F16.38B9520C@aetec.ee>
Remco Poelstra wrote:
> Because I'm writing a program that does some matrix calculations and
> outputs to povray.
> Now I was wondering how the matrices on
> http://enphilistor.users4.50megs.com/matrix.htm
> are constructed. I redesigned them by hand, and came out by the same
> matrices, except that I use the second method to multiply. ie, the
> vector as a column, not a row.
> 
If 3x3 matrix (i.e. without transformations) is used then matrix is
same, regardless of multiplying vector row with matrix (i.e. vectors are
seen as rows) or matrix with vector column (vectors are seen as
columns). Difference comes, when You use 4x4 matrix, then matrix is
different (translation is either in last row or column).


Post a reply to this message

From: Vahur Krouverk
Subject: Re: rotating around x-axis inside povray
Date: 27 Feb 2001 08:09:40
Message: <3A9BA72C.FA4D5AE2@aetec.ee>
Vahur Krouverk wrote:
> 
> If 3x3 matrix (i.e. without transformations) is used then matrix is
                              ---------------
Duh, it should be------------> translations


Post a reply to this message

From: Josh English
Subject: Re: rotating around x-axis inside povray
Date: 27 Feb 2001 08:39:12
Message: <3A9BAE6C.7589C512@spiritone.com>
Vahur Krouverk wrote:

> Remco Poelstra wrote:
> > Because I'm writing a program that does some matrix calculations and
> > outputs to povray.
> > Now I was wondering how the matrices on
> > http://enphilistor.users4.50megs.com/matrix.htm
> > are constructed. I redesigned them by hand, and came out by the same
> > matrices, except that I use the second method to multiply. ie, the
> > vector as a column, not a row.
> >
> If 3x3 matrix (i.e. without transformations) is used then matrix is
> same, regardless of multiplying vector row with matrix (i.e. vectors are
> seen as rows) or matrix with vector column (vectors are seen as
> columns). Difference comes, when You use 4x4 matrix, then matrix is
> different (translation is either in last row or column).


Actually, they don't. If v = <a,b,c> and M is a 3x3 matrix, multiplying the
row vector on the left gives you a different answer than multiplying the
column vector on the right.
v = <a,b,c>
M = d e f
       g h i
       j k l

vM = <ad+bg+dj, ae+bh+ak, af+bi+cl>
Mv = <ad+be+cf, ag+bh+ci, aj+bk+bl>

If you switch the order of the vector and the matrix, you have to transpose
the matrix

--
Josh English -- Lexiphanic Lethomaniac
eng### [at] spiritonecom
The POV-Ray Cyclopedia http://www.spiritone.com/~english/cyclopedia/
"He who hebetates is last."


Post a reply to this message

From: Vahur Krouverk
Subject: Re: rotating around x-axis inside povray
Date: 27 Feb 2001 09:05:40
Message: <3A9BB449.899ED163@aetec.ee>
Josh English wrote:
> 
> Vahur Krouverk wrote:
> [Something very false]

> Actually, they don't.

Duh, of course, You're right :-( Next time I'll think more carefully,
what I write. 

I'll not post false facts to usenet.
[98 x more]
I'll not post false facts to usenet.


Post a reply to this message

From: Margus Ramst
Subject: Re: rotating around x-axis inside povray
Date: 27 Feb 2001 14:43:33
Message: <3A9C044A.51FD6E87@peak.edu.ee>
Vahur Krouverk wrote:
> 
> I'll not post false facts to usenet.
> [98 x more]
> I'll not post false facts to usenet.

Not bad, but this is not usenet - better try it again and this time add
"... or private news servers"
:)

-- 
Margus Ramst

Personal e-mail: mar### [at] peakeduee
TAG (Team Assistance Group) e-mail: mar### [at] tagpovrayorg
Home page http://www.hot.ee/margusrt


Post a reply to this message

From: Tom Melly
Subject: Re: rotating around x-axis inside povray
Date: 1 Mar 2001 04:51:35
Message: <3a9e1ba7$1@news.povray.org>
"Margus Ramst" <mar### [at] peakeduee> wrote in message
news:3A9C044A.51FD6E87@peak.edu.ee...
> Vahur Krouverk wrote:
> >
> > I'll not post false facts to usenet.
> > [98 x more]
> > I'll not post false facts to usenet.
>
> Not bad, but this is not usenet - better try it again and this time add
> "... or private news servers"
> :)
>

#declare N = 1;
#while(N<=100)
  #debug "I'll not post false facts to news.povray.org\n" #declare N = N +
1;
#end


Post a reply to this message

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