Corrado
Member
|
Matrix setting
Hello Grzeg,
how set contemporarily on a matrix the following :
angles, scale, positions ?
i try with this :
{
m.setRotateZ(z)).rotateXY(x, y)).scale(scale);
m.pos = Pos;
}
and others ...
but i don't succeed in getting all the 3 contemporarily on a matrix.
Tks and Bye,
Corrado
|
|
07-14-2009 12:22 PM |
|
Esenthel
Administrator
|
Re: Matrix setting
Hi,
I think the codes that you're using are correct.
are you sure youre getting bad results? if so, then what would you like to achieve, and what are you achieving?
|
|
07-14-2009 06:18 PM |
|
Corrado
Member
|
Re: Matrix setting
...
if i set the angles and then the scale -> it seems that when i set the scale i lost the angles
and
if i set the scale and then the angles -> it seems that when i set the angles i lost the scale
Corrado
|
|
07-14-2009 08:04 PM |
|
Esenthel
Administrator
|
Re: Matrix setting
Matrix m;
m.setRotateZ(z)).rotateXY(x, y));
now if you'd do 'setScale' then you'd lose the info about rotation
but you're using 'scale' which is fine
are you using exactly this code?
Code:
m.setRotateZ(z).rotateXY(x,y).scale(scale);
m.pos = Pos;
|
|
07-14-2009 08:13 PM |
|
Corrado
Member
|
Re: Matrix setting
yes i used the code that i sent you (my first choice was this code, then others, but with the same bad result).
Can you check if "scale" reset the angles values ?
(if scale is correct -> i have another error that I don't succeed in seeing in another part of the program)
|
|
07-14-2009 08:29 PM |
|
Esenthel
Administrator
|
Re: Matrix setting
'scale' method doesn't reset the angles, it just applies a scaling factor
|
|
07-15-2009 08:30 PM |
|