ZenHAX

Free Game Research Forum | Official QuickBMS support | twitter @zenhax | SSL HTTPS://zenhax.com
It is currently Wed Mar 29, 2017 3:12 am

All times are UTC




Post new topic  Reply to topic  [ 16 posts ] 
Author Message
PostPosted: Thu Dec 08, 2016 8:46 pm 

Joined: Thu Dec 08, 2016 8:35 pm
Posts: 9
Hi guys,

First time posting here.

Is there anyone with coding knowledge willing to create a parser of some sort or a script to import a seemingly unknown (more like unspecified) 3d format? I'm assuming the format must be some form or variation of XSI (associated with Softimage XSI) but I can't say that for sure.

The reason I'm assuming it must be XSI (or something related) is because the file is from the Xbox 360 game Project Gotham Racing 4.

Luigi Auriemma kindly created a script that can extract the contents of the pak_hrd and some of the .pak files. :)

The .pak files' content I've seen maintains it's original file extensions and are mostly text files.

The .pak_hrd are given the .dat extension by quickbms (these are the ones I suspect to be XSI or XSI related)

Any help would be highly appreciated.

Many thanks in advance

Cheers :)


Top
   
PostPosted: Tue Jan 03, 2017 11:24 pm 

Joined: Thu Dec 08, 2016 8:35 pm
Posts: 9
Here's the BMS extracted file in case anyone is interested or just curious

https://www.mediafire.com/folder/syra7z ... _Extracted

Regards


Top
   
PostPosted: Wed Jan 04, 2017 2:34 am 
User avatar

Joined: Fri Aug 08, 2014 1:06 am
Posts: 232
this doesn't look like any xsi file i have ever seen, i can't see any obvious
patterns or data that make sense either maybe is encrypted or something. :?


Top
   
PostPosted: Wed Jan 04, 2017 7:33 am 

Joined: Sun Mar 22, 2015 7:09 pm
Posts: 590
Nothing that bad. Data is compressed with zlib. Separate data blocks for geometry, faces and textures.


Top
   
PostPosted: Wed Jan 04, 2017 9:23 am 
User avatar

Joined: Fri Aug 08, 2014 1:06 am
Posts: 232
yep you can run it through offzip to get uncompressed headerless files :oops:
Code:
offzip -a 0000000000000000.dat c:\offzip\extracted


Image
Attachment:
00082fc6.dat.png [108.06 KiB]
Not downloaded yet


Top
   
PostPosted: Wed Jan 04, 2017 11:08 am 

Joined: Thu Dec 08, 2016 8:35 pm
Posts: 9
Many thanks for the replies, guys :)

I'll look into it :)


Top
   
PostPosted: Wed Jan 04, 2017 12:36 pm 

Joined: Thu Dec 08, 2016 8:35 pm
Posts: 9
A noob question: How did you determine that specific file's extension? Or did you take the data and made a png file from the contents of the .dat archive?


Top
   
PostPosted: Thu Jan 05, 2017 4:28 am 
User avatar

Joined: Fri Aug 08, 2014 1:06 am
Posts: 232
dissectionalone wrote:
Or did you take the data and made a png file from the contents of the .dat archive?

yes that, the texture data was typical big-endian and tiled dxt for X360. texture data is easy to identify
when you look at enough of them. there was no header so i used file size to determine the dimensions
and then experimented with formats from there and used Noesis to convert it png so i could post it here.


Top
   
PostPosted: Thu Jan 05, 2017 2:13 pm 

Joined: Thu Dec 08, 2016 8:35 pm
Posts: 9
I've been trying to figure out ways of identifying all those data blocks, trying to extract that Lamborghini Diablo model but had no luck so far. Those headless binary files feel like advanced chinese


Top
   
PostPosted: Thu Jan 05, 2017 5:27 pm 

Joined: Sun Mar 22, 2015 7:09 pm
Posts: 590
all "header" information is stored in .dat file itself, between ZLIB compressed blocks. Coordinates are not float, but shorts probably. Faces done with tri-strips with FFFF terminators. I just took a quick look at that.


Top
   
PostPosted: Thu Jan 05, 2017 7:03 pm 

Joined: Thu Dec 08, 2016 8:35 pm
Posts: 9
id-daemon wrote:
all "header" information is stored in .dat file itself, between ZLIB compressed blocks. Coordinates are not float, but shorts probably. Faces done with tri-strips with FFFF terminators. I just took a quick look at that.


I'll try to dig up the info from there. Thanks for the info :)


Top
   
PostPosted: Mon Jan 09, 2017 8:50 pm 

Joined: Thu Dec 08, 2016 8:35 pm
Posts: 9
I've tried looking at the original file, without using the offzip command to extract all the data and generate a bunch of headless .dat files, and tried searching for certain strings using a hex editor (you know trying to locate some standard format reference like DDS or FBX) and found a couple but I'm not sure if those are correct or actual meaningful references that can Id the formats.


Top
   
PostPosted: Mon Jan 09, 2017 9:49 pm 
User avatar

Joined: Fri Aug 08, 2014 1:06 am
Posts: 232
in 0000000000000000.dat it looks like each file has an uncompressed 51 byte header preceeding each compressed block
i guess a really good bms script could write out the headers and append them to the decompressed file data.
there might be a flag which tells what type of file it is
the last 8 bytes of each header has the uncompressed size and compressed size in big endian byte order


Top
   
PostPosted: Mon Jan 09, 2017 11:15 pm 

Joined: Thu Dec 08, 2016 8:35 pm
Posts: 9
That flag might probably be what makes quickbms decide what file extension to give the extracted content right?
Could you elaborate a bit on that idea of the headers with a screenshot, please? Just so I can make sure I'm following.


Top
   
PostPosted: Mon Jan 09, 2017 11:34 pm 
User avatar

Joined: Fri Aug 08, 2014 1:06 am
Posts: 232
well you would set script to read the flag in the header and give certain files a better extension.
when you use offzip to extract the files they are named by their starting offset, 000046e3.dat
is the first file extracted at 0x46e3 and if you go back 51 bytes in the main dat file you are at
the start of the header for that file at 0x46b0


Top
   
PostPosted: Tue Jan 10, 2017 12:06 am 

Joined: Thu Dec 08, 2016 8:35 pm
Posts: 9
So the first byte at 0x46e3 which has a 78 that indicates it's zlib compressed? Or am I confusing it? Shouldn't the beginning of the header have an indication of what type file it is?


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 16 posts ] 

All times are UTC


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Powered by phpBB® Forum Software © phpBB Limited