Jump to content
  • Advertisement


This topic is now archived and is closed to further replies.


3D Studio - matrix

This topic is 5717 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi, I have read several documents about the file format of .3ds-file, but there is never a good description of the matrix you can find at the chunk 0x4160. I am using Direct3D. how do I have to load this matrix correct? I never got a good result. my legs, head, body etc. were all over the screen, but not at the right place. I tried:
//my matrix:

float m[4][4];  //the same like direct3d uses


//and then

(I know the syntax is not correct here) but something is wrong.. do i have to use two matrices, a translation and rotation or something like that? [edited by - kudi on April 18, 2003 12:03:04 PM]

Share this post

Link to post
Share on other sites
Here is some particularly awful code that loads this matrix:

case 0x4160:
{ // Local transformation matrix
int i, j;
if(tail == NULL) break;
for (j=0;j<4;j++)
for (i=0;i<3;i++)
{ fread(&(tail->lmat[j]),sizeof(float),1,bin3ds);

Share this post

Link to post
Share on other sites

  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!