Page 1 of 4

xmx 3D files Sega GT 2002

Posted: Sun Jun 01, 2014 3:43 pm
by KarinFutoGT
Hello guys i've been looking 1 year ago how to extract the sega gt '02, I got it at the end but there are files with extension .xmx I looked a lot of pages at google without luck, someone know if exits a tool/program to open or convert to other format like .obj? I guess not [bruce]

Here is a 3D with .xmx format

Re: xmx 3D files Sega GT 2002

Posted: Mon Jun 02, 2014 4:50 am
by TomWin
Oh man this game has some cool models. I always wanted jottio caspita can u upload it to? Sorry I don't have coding skills

Re: xmx 3D files Sega GT 2002

Posted: Wed Jun 04, 2014 2:51 pm
by Guerra8888
nice cars... very interesting

Re: xmx 3D files Sega GT 2002

Posted: Thu Jun 05, 2014 12:05 am
by pivke
Shouldn't be too difficult to crack this format up and convert it to OBJ. In the file, there are sections like Material, Vertex, Index-List etc. You can even clearly see the vertex-coordinates and indices. But for now I'm unable to find anything about offset's or size's. Do you have a smaller file?

EDIT://
As it seems, these files aren't standalone-files. It looks like each file has a reference file. Can't find any information about vertex-stride, vertex-count etc. As I already requested; Can you provide a smaller file? Huge files are always more difficult to reverse...

Re: xmx 3D files Sega GT 2002

Posted: Fri Jun 06, 2014 10:50 pm
by Guerra8888
would be great to see these models
:wink:

Re: xmx 3D files Sega GT 2002

Posted: Sat Jun 07, 2014 4:09 pm
by KarinFutoGT
Here is a small .xmx, i guess is the fan from showroom

Re: xmx 3D files Sega GT 2002

Posted: Sat Jun 07, 2014 6:51 pm
by shakotay2
using hex2obj (view link in my sig):
dom_zero_01a_body.JPG
(There seem to be superfluous faces inside the chassis when viewing the obj in blender for example.)

There are 18 assumed starts of face indices blocks (0000 0100 0200...) after 0x2E9E8. Didn't check them.

Re: xmx 3D files Sega GT 2002

Posted: Sat Jun 07, 2014 9:23 pm
by pivke
car.png
So, I have some good news for you.

Code: Select all

XMX-Files
==============================
Byte { 16 } - Header
{
     Byte { 8 } - File Identification ("LDMXXOBX") -> "XboxModel"
     Dword { 4 } - Number Of Sections (see below)
     Dword { 4 } - File Size - 16 byte (Header Size)
}

Byte { x } - Section
{
     Byte { 4 } - Section Name
     if Section Name  == "LEDM" -> "Model"
        then
        {
             Byte { 41 } - Unknown
             Dword { 4 } - Vertex Count (see below)
        }
      Byte { x } - Unknown
}

To get the vertices, just read the next bytes till there comes "XTRV" ("Vertex"). When you reached this section, the data is:
Byte { x } - Section
{
     Byte { 4 } - Section Name
     if Section Name  == "XTRV" -> "Vertex"
        then
        {
             Float { 4 } - Vertex X
             Float { 4 } - Vertex Y
             Float { 4 } - Vertex Z
             Float { 4 } - Unknown

             Float { 4 } - UV X
             Float { 4 } - UV Y
        }
}
There are other sections like "RTAM" -> "Material" or "MNXTVPRG" -> "GroupVertex". I think it's obvious what they are describing.
After the "XTRV"-Section, immadiately the "XDNI" -> "Index" starts. That section starts as any section too with it's "Section Name" ( Byte { 4 } ).

(legend: "->" (without quotes) means "could mean")
==============================

So, thats what I found so far. As it looks, the UV in the VBO starts somewhere around the 16th byte. As for now, I was not able to find any information about the Face count. The "MNXTVPRG" should be analyzed a bit deeper that I did. When somebody is able to find some more relevant information like offset to VBO and/or Facecount, I'm ready to write a small application to convert this to the obj-format. But anyway, it is going to be hard to convert the models back to .xmx...

Re: xmx 3D files Sega GT 2002

Posted: Sun Jun 08, 2014 2:50 am
by KarinFutoGT
Are very good news for me, not know nothing about programming but this is really great, no want to return to .xmx just edit the 3D :keke:
Thanks for your time :]

Re: xmx 3D files Sega GT 2002

Posted: Sun Jun 08, 2014 9:26 am
by shakotay2

Code: Select all

Offset   0  1  2  3  4  5  6  7   8  9  A  B  C  D  E  F

010D0   02 00 00 00 00 00 00 00  4D 4E 58 54 56 50 52 47   ........MNXTVPRG
010E0   8C 01 00 00 00 00 00 00 >66 0C 00 00 00 00 00 00  -- vertex count
010F0  >2C 16 00 00 00 00 00 00  00 00 00 00 00 00 00 00  -- face indices count
vertex count is 0xC66 = 3174 , face indices count is 0x162C = 5676 -> 1892 faces

Not sure about the face indices count. as from the list it should be 5772.
edit: pivke seems to be right, 162C looks like an offset

There's another chassis at 0x13FFC but I got a point cloud only because I don't know which face indices belonging to it. Same goes for 0x2698C, but there are 1369 vertices only.
(You can increase the point's size by pressing 'p' in hex2obj. shift-p to decrease)

Re: xmx 3D files Sega GT 2002

Posted: Sun Jun 08, 2014 12:43 pm
by pivke
Hey shakotay2,

nice, you've did some research of the Groups. We quite get more far :)

So, I've looked at your results, but I think the structure has some other order. What do you think about this:


MNXTVPRG8C01000000000000660C0000000000002C16

MNXTVPRG = "GroupVertex" (obvious)
8C01000000000000 = Unknown
660C = Vertex Count for this group (0x0C66 = 3174 vertices of 7719 total vertices)
000000000000 = Unknown
2C16 = Offset to VERTEX-section (0x162C = Begin-Of-"XTRV"-Section -= 16 byte) (Those 16 byte could be some general information about vertices, maybe flags?!)

I think what I wrote above is quite right. Because everything starts making sense for now. So the "MODEL"-section keeps things like total Total-Vertex-Count and Total-Face-Count, just as the section ID says. And the "GROUPVERTEX"-section is like grouping in *.obj-files.

So what we have to do for now, is checking the "GROUPVERTEX"-section for counts, and offsets. And check if the offsets are "array"-offsets or "byte"-offsets.

Keep up the good work, the circle about this formats is gonna be closing :)

Re: xmx 3D files Sega GT 2002

Posted: Tue Jun 10, 2014 8:41 pm
by Karpati
KarinFutoGT,

I finished the hacking of the .xmx format. Here I attached the converted .obj/mtl files to check out the result.
Next day I will upload an application and you can see your .xmx object directly without any tricks.
If you will confirm that works correctly, I will share the missing information.

(I must shut down my PC now...)

Re: xmx 3D files Sega GT 2002

Posted: Tue Jun 10, 2014 9:40 pm
by pivke
@Karpati
Cool, good work! Could you share your research with us? Would be interesting :)

Re: xmx 3D files Sega GT 2002

Posted: Wed Jun 11, 2014 7:11 am
by KarinFutoGT
Thanks for all just tried right now and uv works correctly Image :lol: :lol:

Re: xmx 3D files Sega GT 2002

Posted: Wed Jun 11, 2014 1:30 pm
by TomWin
Please could you upload more models? Jottio Caspita