Jump to content
  • Advertisement
Sign in to follow this  
mono_eric3

.X file compression format?

This topic is 4162 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

Does anyone know exactly how model data is compressed in a binary compressed x file? The actual file is not a zip file and after removing the directx header the files are still not zip files. Has anyone managed to decompress an X file? D.

Share this post


Link to post
Share on other sites
Advertisement
The binary format is described in the DX SDK help file. If you look up 'Binary Encoding' in the index you will find it. I havn't tried to parse the binary data myself though.

You can always create a small app that loads the x file using D3DXLoadMeshHierarchyFromXInMemory(). As you load the file you will have access to the vertexes, keys, textures etc.

Share this post


Link to post
Share on other sites
The SDK docs give the name:
"tzip" MSZip Compressed Text File
"bzip" MSZip Compressed Binary File

MSZip is the compression algorithm. It looks like an algorithm developed by Microsoft.

I've read somewhere it is the same algorithm used in .cab files, so
I would suggest looking for source code related to reading/writing CABs.

If you get it working, let me know! :)

Share this post


Link to post
Share on other sites
Thanks for the tip - it is indeed stored in CAB format.

I'll do a little more research on the formats to see if I can create a header that will allow them to be unpacked.

D.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • 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!