Important information: this site is currently scheduled to go offline indefinitely by end of the year.

Extracting simple models

Read or post any tutorial related to file format analysis for modding purposes.
SchnelleMeyer
beginner
Posts: 27
Joined: Sun Feb 26, 2017 10:28 pm
Has thanked: 9 times
Been thanked: 4 times

Re: Extracting simple models

Post by SchnelleMeyer »

shakotay2 wrote:Great! :) (One of a thousand who understands how to use the tool. :D )
I dont know about the understanding part, but I have extracted a few models from different games now and I find it kind of forgiving in some areas like when I search for the correct FI counts cause I am too lazy to do the math.
shakotay2 wrote:it's not a matter of its capability, it's a matter of your creativity. :D
Trying out a point cloud, too tired to care fore face indicies:
- I am back working on the Muj character though and have had some progress I think although my data are very different from those in your post.
I have successfully extracted the UVs - I belive this means that my FI start adress and count is correct as well as the verts count.
Muj 1 progress.PNG
So what I am struggling with is finding the vertices start adress. - If you or anyone can take a second look at the Muj I would be gratefull :D
You do not have the required permissions to view the files attached to this post.
User avatar
shakotay2
MEGAVETERAN
MEGAVETERAN
Posts: 4284
Joined: Fri Apr 20, 2012 9:24 am
Location: Nexus, searching for Jim Kirk
Has thanked: 1146 times
Been thanked: 2242 times

Re: Extracting simple models

Post by shakotay2 »

I can see a promising part of a surface here:
muja1.jpg
(seems there's not more than 1243 valid vertices up to 0xE0D3)
You do not have the required permissions to view the files attached to this post.
Tuts: a) Bigchillghost, viewtopic.php?f=29&t=17889
b) Extracting simple models: http://forum.xentax.com/viewtopic.php?f=29&t=10894
"Quoting the whole thing. Would u ever stop this nonsense?"
SchnelleMeyer
beginner
Posts: 27
Joined: Sun Feb 26, 2017 10:28 pm
Has thanked: 9 times
Been thanked: 4 times

Re: Extracting simple models

Post by SchnelleMeyer »

Good work Shakotay! - Thanks a lot for helping out here!

Seems you've found the correct verts start adress. - The point cloud looks even cleaner now.
Increasing the FI count above 111 causes the faces to go all over the place, I dont understand why.. - the FI numbering is sorted in a special way maybe?
User avatar
shakotay2
MEGAVETERAN
MEGAVETERAN
Posts: 4284
Joined: Fri Apr 20, 2012 9:24 am
Location: Nexus, searching for Jim Kirk
Has thanked: 1146 times
Been thanked: 2242 times

Re: Extracting simple models

Post by shakotay2 »

SchnelleMeyer wrote:Increasing the FI count above 111 causes the faces to go all over the place, I dont understand why..
look into the test.obj - contains non valid vertices in that case
- the FI numbering is sorted in a special way maybe?
you can try to comment out all faces whose indices are above 1243:
muja_head.jpg
[...]
f 1120 1121 1086
f 1086 1087 1120
#f 1109 1498 1502
#f 1502 1108 1109
f 1128 1088 1113
f 1116 1117 1155
[...]

(You will have to delete the non-valid vertices from the test.obj, i.e. vertex 1244 and so on...)
You do not have the required permissions to view the files attached to this post.
Tuts: a) Bigchillghost, viewtopic.php?f=29&t=17889
b) Extracting simple models: http://forum.xentax.com/viewtopic.php?f=29&t=10894
"Quoting the whole thing. Would u ever stop this nonsense?"
SchnelleMeyer
beginner
Posts: 27
Joined: Sun Feb 26, 2017 10:28 pm
Has thanked: 9 times
Been thanked: 4 times

Re: Extracting simple models

Post by SchnelleMeyer »

Thanks again for good hints!

Its getting there now. - There are much better models out there, no doubt, but this one turned into a quest :mrgreen:
You do not have the required permissions to view the files attached to this post.
Xr79
veteran
Posts: 91
Joined: Sat Oct 05, 2013 11:45 pm
Has thanked: 19 times
Been thanked: 3 times

Re: Extracting simple models

Post by Xr79 »

hey there! I found this thread, but I feel like I might be to late. I have a .MLX file that is from Valkryia chronicles 2. and from my research it is a Hex file that is a mesh model, I'm wondering if anyone could help me? I found something that says the start is IZCA. It would be amazing if someone could help me. here are the MLX files. any one got a clue?

https://www.dropbox.com/s/64eh80s1lkkx7 ... s.rar?dl=0
User avatar
shakotay2
MEGAVETERAN
MEGAVETERAN
Posts: 4284
Joined: Fri Apr 20, 2012 9:24 am
Location: Nexus, searching for Jim Kirk
Has thanked: 1146 times
Been thanked: 2242 times

Re: Extracting simple models

Post by shakotay2 »

Fake tri strips used:
SWG12B_MLX.jpg
You do not have the required permissions to view the files attached to this post.
Tuts: a) Bigchillghost, viewtopic.php?f=29&t=17889
b) Extracting simple models: http://forum.xentax.com/viewtopic.php?f=29&t=10894
"Quoting the whole thing. Would u ever stop this nonsense?"
PaulBuryCZ
ultra-n00b
Posts: 5
Joined: Sun Aug 16, 2015 11:12 pm
Has thanked: 4 times
Been thanked: 1 time

Re: Extracting simple models

Post by PaulBuryCZ »

Since the more I try Hex2Obj, the more I understand that my brain won't ever understand this, so I have to ask for assistance.

I have an extensionless should-be mesh from Etherlords 2, and after 4 days of looking at the file, (I think) I know the face indices but nothing else I guess.

Face indices:
startadress: 4480
count: 645

It should look similar to this (it's ripped mid-animation though):

Image

Any help is appreciated...
You do not have the required permissions to view the files attached to this post.
User avatar
shakotay2
MEGAVETERAN
MEGAVETERAN
Posts: 4284
Joined: Fri Apr 20, 2012 9:24 am
Location: Nexus, searching for Jim Kirk
Has thanked: 1146 times
Been thanked: 2242 times

Re: Extracting simple models

Post by shakotay2 »

well, just another format that doesn't make sense to me; there's a good chance that it's animation data.

For the face indices, seems you got the wrong ones.
i'd try the ones from 0x2B58 to 0x3AA0
size of block: 0xF48 -> 3912/2= 1956 face indices count
resulting in an assumed vertex count of 421.

The ones from 0x4480 do have too many "doubles":

Code: Select all

Offset 0  1  2  3  4  5  6  7   8  9  A  B  C  D  E  F
04480 00 00 01 00 01 00 02 00  02 00 03 00 03 00 04 00
04490 04 00 05 00 05 00 06 00  06 00 07 00 07 00 08 00
But the weird thing is to get a point cloud, first naive idea would be:
vertices from
0x28 - 0x2230 = 0x2208 -> 8712 / 421 = 20 FVFsize

But at no avail; tried many other FVF sizes, 48, 24, 12, 16, 32 and other vertex start addresses: no dam.., sry, decent point cloud to be found. I'm running out of time so you're on your own now...
Tuts: a) Bigchillghost, viewtopic.php?f=29&t=17889
b) Extracting simple models: http://forum.xentax.com/viewtopic.php?f=29&t=10894
"Quoting the whole thing. Would u ever stop this nonsense?"
PaulBuryCZ
ultra-n00b
Posts: 5
Joined: Sun Aug 16, 2015 11:12 pm
Has thanked: 4 times
Been thanked: 1 time

Re: Extracting simple models

Post by PaulBuryCZ »

It's alright. The files are a mess anyway.

Thanks for your time and Merry Christmas!
Protocol X27
ultra-veteran
ultra-veteran
Posts: 341
Joined: Wed Dec 14, 2011 5:46 pm
Has thanked: 141 times
Been thanked: 128 times

Re: Extracting simple models

Post by Protocol X27 »

I love how this app has made some recent projects a reality. Thanks again for making this!

One curiosity question. Would it be possible to add a flag to Flip UV's on the vertical axis? I have a tendency to forget to always flip them to match texture when I'm in Blender, so I ask as a means of time saving to override user error, lol. I don't know vertex structure well enough to know if that would involve some crazy matrix math or if it's as simple as multiplying all values times a singular value. If it's crazy no worries, but thought I'd at least check. Of course, if there's any tricks I'm missing that's cool too.

Edit: Oh, and I've noticed that when a mesh is split into multiple objects an when I export them, they all have an origin at the center, so I have to realign them in Blender. I saw on the front page something about multi mesh. Is there some kind of trick to get them all imported at once so they are lined up correctly. I haven't done anything beyond single imports/exports.
User avatar
shakotay2
MEGAVETERAN
MEGAVETERAN
Posts: 4284
Joined: Fri Apr 20, 2012 9:24 am
Location: Nexus, searching for Jim Kirk
Has thanked: 1146 times
Been thanked: 2242 times

Re: Extracting simple models

Post by shakotay2 »

Protocol X27 wrote:I love how this app has made some recent projects a reality. Thanks again for making this!
you're welcome. :)
One curiosity question. Would it be possible to add a flag to Flip UV's on the vertical axis? [..] or if it's as simple as multiplying all values times a singular value.
it's just ty_flipped= 1 - ty
I can send you a newer (i.e. one year old) version of hex2obj for testing (but I'm sure to have introduced new bugs) as soon as I'm home again in 2 days or so.
Edit: Oh, and I've noticed that when a mesh is split into multiple objects an when I export them, they all have an origin at the center, so I have to realign them in Blender.
I'd need a sample file. Some formats use extra offsets for the realignment.
Tuts: a) Bigchillghost, viewtopic.php?f=29&t=17889
b) Extracting simple models: http://forum.xentax.com/viewtopic.php?f=29&t=10894
"Quoting the whole thing. Would u ever stop this nonsense?"
Protocol X27
ultra-veteran
ultra-veteran
Posts: 341
Joined: Wed Dec 14, 2011 5:46 pm
Has thanked: 141 times
Been thanked: 128 times

Re: Extracting simple models

Post by Protocol X27 »

it's just ty_flipped= 1 - ty
I can send you a newer (i.e. one year old) version of hex2obj for testing (but I'm sure to have introduced new bugs) as soon as I'm home again in 2 days or so.
That'd be neat if it works out. No rush!
I'd need a sample file. Some formats use extra offsets for the realignment.
Cool, here's a basic one using the recent MGF stuff. This is a 3 part of the higher poly pilot model I found. I included the mgf and condensed the stats down to the values for just these meshes. This of course is a really simple example since only one part is misaligned and easy to adjust. One set is pre-alignment, the other is after. In the case of Ninja Gaiden content, some of the character models were like 40+ meshes and all centered at the origin which is really time consuming to align. If there's some shortcuts to speed this up, fantastic, if not no worries, just the nature of the beast. I'll have to dig back through my Ninja Gaiden assets if you think the more complicated one would serve as a better sample.

Thanks for any extra insight! :)

http://www.mediafire.com/file/0g3sp6uge ... Sample.zip

Image
User avatar
shakotay2
MEGAVETERAN
MEGAVETERAN
Posts: 4284
Joined: Fri Apr 20, 2012 9:24 am
Location: Nexus, searching for Jim Kirk
Has thanked: 1146 times
Been thanked: 2242 times

Re: Extracting simple models

Post by shakotay2 »

well, I had the feeling I completely forgot about the positioning problem but then I realized that I answered here:
viewtopic.php?f=16&t=17962&p=139794&hilit=mgf#p139794


For that "flipping uvs" thingie I've to admit that it appears to be too hard to implement into hex2obj although it's a simple feature. Problem is that I would have to put it into dozens of function combinations. floats, halffloats, shorts, combined with vertices or uvs functions plus the same set of functions for the listing in the left most listbox, for the test.obj file (mesh button) and for the SaveAs mesh menu entry. (This is indeed the first time I wish I'd coded it object orientated :cry:)

A shitload of work, which I try to avoid.
Tuts: a) Bigchillghost, viewtopic.php?f=29&t=17889
b) Extracting simple models: http://forum.xentax.com/viewtopic.php?f=29&t=10894
"Quoting the whole thing. Would u ever stop this nonsense?"
User avatar
Bigchillghost
double-veteran
double-veteran
Posts: 1023
Joined: Tue Jul 05, 2016 9:37 am
Has thanked: 31 times
Been thanked: 1210 times

Re: Extracting simple models

Post by Bigchillghost »

shakotay2 wrote: Problem is that I would have to put it into dozens of function combinations. floats, halffloats, shorts, combined with vertices or uvs functions plus the same set of functions for the listing in the left most listbox, for the test.obj file (mesh button) and for the SaveAs mesh menu entry. (This is indeed the first time I wish I'd coded it object orientated :cry:)

A shitload of work, which I try to avoid.
So you do all the works in every single function combination? Why not just read the vertices/UVs data to a temporary buffer and convert/copy them to the destination buffer? Then you need to process only one buffer if the flipping UVs option is chosen.

BTW I'm still confused about the UI. What are the w/64k / w/8k and the grey CF buttons for?
Also, I noticed that the exported mesh is grouped per 500 triangles, is it because the face buffer is that big, or that it's a designed feature? I wish I don't have to blocked them out every time.
May you find peace in this puzzle-solving game. Say it with action: click the Image when you get helped.:)
Post Reply