ralph78
asked on
direct 3d transform
Hi!
i'm working with directx 8 and i wanna create a 3d app(c++).
for each object i wanna use, i store all rotations, all scales and all translations. (in each direction (x,y,z)).
so, when i want to render a object, i call
D3DXMatrixTransformation(& matworld,N ULL,&t_rot ations,&t_ scales,NUL L,NULL,&t_ translatio ns);
and just before rendering
dxmanager->lpd3ddev->SetTr ansform(D3 DTS_WORLD, &matworld);
it seems to work when my object is only scales and/or translated, but when i try to rotate it... the scale doesn't work anymore...
pleeeaaase heeeeeelp!!
thanks, Ralph
i'm working with directx 8 and i wanna create a 3d app(c++).
for each object i wanna use, i store all rotations, all scales and all translations. (in each direction (x,y,z)).
so, when i want to render a object, i call
D3DXMatrixTransformation(&
and just before rendering
dxmanager->lpd3ddev->SetTr
it seems to work when my object is only scales and/or translated, but when i try to rotate it... the scale doesn't work anymore...
pleeeaaase heeeeeelp!!
thanks, Ralph
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
You're using the wrong rotation parameter. I assume you want to rotate the object, in which case you should use the rotation and rotation centre parameters, not the "scaling rotation" which you're using in the code you posted.
ralph78:
This old question needs to be finalized -- accept an answer, split points, or get a refund. For information on your options, please click here-> http:/help/closing.jsp#1
EXPERTS:
Post your closing recommendations! No comment means you don't care.
This old question needs to be finalized -- accept an answer, split points, or get a refund. For information on your options, please click here-> http:/help/closing.jsp#1
EXPERTS:
Post your closing recommendations! No comment means you don't care.