Jump to content
  • Advertisement

Archived

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

3dmax to a propertary bin format problem

This topic is 5191 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 try to export a model and write the info in a bin format , but i have a prblem when i write the tvFaces in the bin file the content is wrong i save the same model in text format and i don''t have a problem , can you tell me what i''m doing wrong , this is the part of my code. DWORD a1=msh->tvFace.t[0]; DWORD a2=msh->tvFace[i].t[0]; DWORD a3=msh->tvFace[i].t[0]; fwrite(&a1, sizeof(DWORD), 1, fp); fwrite(&a2, sizeof(DWORD), 1, fp); fwrite(&a3, sizeof(DWORD), 1, fp);

Share this post


Link to post
Share on other sites
Advertisement
Guest Anonymous Poster
shouldnt it be like this?

DWORD a1=msh->tvFace.t[0];
DWORD a2=msh->tvFace[i].t[1];
DWORD a3=msh->tvFace[i].t[2];


Share this post


Link to post
Share on other sites
By the way, The board is turning the first tvFace.[ i ].t[0]; and making it into board format for italics, so it looks like tvFace.t[0];


Edit: Typed too fast!

[edited by - LiyonDR on March 4, 2004 10:37:32 PM]

Share this post


Link to post
Share on other sites
tks for the answer! :D , i fix this midnigth-tipe error but i stell have an error in the bin here is the new code



DWORD a1=(DWORD)msh->tvFace[count].t[0];
DWORD a2=(DWORD)msh->tvFace[count].t[1];
DWORD a3=(DWORD)msh->tvFace[count].t[2];


fwrite(&a1, sizeof(DWORD), 1, fp);
fwrite(&a2, sizeof(DWORD), 1, fp);
fwrite(&a3, sizeof(DWORD), 1, fp);



can anyone see something wrong? , the plug-in is for 3DSMAX 5
txs in advance!

[edited by - juglarx on March 5, 2004 6:36:27 PM]

Share this post


Link to post
Share on other sites
Hi dudes i found something the problem is when i write a 10 in the file (extranger) i view the bin file with a HexView an i see the represatation of 10 is 0DOA00 and the correct value shuold be 0A0000 i check the sign and is Positive.... anyone can help me ?

[edited by - juglarx on March 5, 2004 6:55:46 PM]

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.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!