Author Topic: CHRONO CROSS FILE EXPLORATION THREAD  (Read 64753 times)

Sora

  • Chronopolitan (+300)
  • *
  • Posts: 362
  • The Terror Of Death
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #210 on: November 27, 2007, 04:59:14 pm »
we are losing T.T

FaustWolf

  • Guru of Time Emeritus
  • Arbiter (+8000)
  • *
  • Posts: 8972
  • Fan Power Advocate
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #211 on: November 27, 2007, 05:05:53 pm »
Thanks for the uplifting observation, Sora. 8)

On that bleak note, I'd like to mention that there a few instances in which "FF" values creep into the quad UV data. Since the UV data shouldn't have that value at all, it's quite likely that my models for the quad and triangle data are flawed, at least in certain areas of Section 1-2. I think Luminaire had reported this oddity earlier - it's almost as if the pointer and the UV map are "switched" in some instances, or it's possible that two quads can point to the same UV map if they both follow that UV map one right after the other perhaps.

Only way to tell for sure is to mess with some data and fire up the emulator. I'll see if I can fit it in later today.

Sora

  • Chronopolitan (+300)
  • *
  • Posts: 362
  • The Terror Of Death
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #212 on: November 27, 2007, 06:01:58 pm »
Luminaire seems to be always right.
instead of doing all these tests, why not just ask him and take his word on it and expand from there?
it seems like it'd be a lot faster.

FaustWolf

  • Guru of Time Emeritus
  • Arbiter (+8000)
  • *
  • Posts: 8972
  • Fan Power Advocate
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #213 on: November 27, 2007, 06:17:30 pm »
Luminaire IS always right. And so are yaz0r, Halkun, Cyb, Gemini, and all the other veteran hackers here. I just like to prove it, that's all. 8)

At the very least Sora, these various experiments have certainly increased my own understanding of how the 3D model format works. I'm sort of an apprentice hacker here - and an apprentice can't keep asking the master for handouts. The apprentice must go through the same work to figure out the tricks of the trade, so to speak.

With that said, time for more experiments! Mwahahah! :mrgreen:

Sora

  • Chronopolitan (+300)
  • *
  • Posts: 362
  • The Terror Of Death
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #214 on: November 27, 2007, 06:23:59 pm »
yes, but things need to go fasterrrrrrrrrrrrrrrrrr~~~~~~~~~~~~~~~~~~~~
its way to slow T.T

ZeaLitY

  • Entity
  • End of Timer (+10000)
  • *
  • Posts: 10795
  • Spring Breeze Dancin'
    • View Profile
    • My Compendium Staff Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #215 on: November 27, 2007, 06:45:15 pm »
What the fuck? Halkun, Luminaire, and the others may be right, but they don't have the time to analyze the file in-depth and map it out completely. That's FW's job, and he uses their great advice to make headway. If you can't be patient, then hack it yourself.

Sora

  • Chronopolitan (+300)
  • *
  • Posts: 362
  • The Terror Of Death
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #216 on: November 27, 2007, 07:11:09 pm »
What the fuck? Halkun, Luminaire, and the others may be right, but they don't have the time to analyze the file in-depth and map it out completely. That's FW's job, and he uses their great advice to make headway. If you can't be patient, then hack it yourself.
ohh, so times the issue, i get it now.

Cyberman

  • Architect of Kajar
  • Earthbound (+15)
  • *
  • Posts: 44
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #217 on: November 27, 2007, 07:40:58 pm »
yes, but things need to go fasterrrrrrrrrrrrrrrrrr~~~~~~~~~~~~~~~~~~~~
its way to slow T.T
I suggest you look at this thread once a week instead, it will seem faster that way.  Otherwise you are just making noise, going off topic, and making it really hard to follow FaustWolf's experimental confirmation of everyone's thoughts and suggestions.  Learning is about making mistakes, proving them wrong, and deciding what is right.

Quote from: FaustWolf
EDIT: Ooh! Hang on! Toward the end of Section 1-1, at offset 0x029C in Serge's untextured model file, there's the value 60 0C, which is Little Endian for 0x0C60, or 3168 -- that's the number of bytes for the triangle map and pointer data. Could it be a clue?
FW that 'number that coincidentally is the size of the triangle data might be an offset to the Quad section if you know how large section 2 is you merely compute the size of the quad section by subtracting that value from the total. Erstwhile you know the triangle section size automatically that way as well as where the quads start.
The vertex indexes are likely what are adjacent to the UV data.  So you have a slightly different polygon format than FF7 that's pretty much it.  The GPU packets are constructed from the 3d data being transformed by the GTE and then married to the UV data to form the final chunks of data so 32 bit alignment is not necessary until you are sending data to the GPU. (IE DMA data used with the GPU, is 32 bit aligned hence why we were discussing that so much).

Cyb

FaustWolf

  • Guru of Time Emeritus
  • Arbiter (+8000)
  • *
  • Posts: 8972
  • Fan Power Advocate
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #218 on: November 27, 2007, 08:26:00 pm »
Phew, Zeality lays the smackdown. :lee:

If it's any consolation Sora, there's only, oh, 5 whole Sections in the character model format we haven't even begun to analyze yet. And that isn't counting subsections.  :D But yaz0r's made major progress on the weapon models at the same time, so everything's going very smoothly all things considered. Admittedly progress probably would have been faster had I abandoned the character models in favor of the weapon models, but I'm really liking the fact that we're looking at more than one type of model at the same time. For example, yaz0r's observation about the presence of triangles AND quads in the weapon models taught me that models aren't necessarily exclusive in the type of polygons they use, which helped shape my experiments examining Section 1-2, etc.

Sora, if you've got the time, I invite you to take a look at the File Structure wiki, which should lead you to the character model sections we haven't started examining yet (the Section offsets are listed in the character battle model headers). You're welcome to dive in yourself and look for interesting hex patterns. Even if you have suggestions on how to improve the battle model format wiki entries, that would be welcome too.

Anyway, here's tonight's food for thought. First, some hex code, followed by pics:



The 8-byte hex strings labeled "1", "2", etc., correspond to the same labels on the pics. Specifically, the pics are the result of zeroing out the corresponding hex string. Now, according to the theory I subscribe to on how Section 1-2 works, hex string #2 should NOT be UV data, because it contains the value "FF" - a value beyond the bounds of the character's battle texture.

HOWEVER -- string #1 is in the correct position to be a UV map for a quad. And it apparently acts as such -- zeroing out its data causes a quad to turn a blackish color without becoming a window through the model. This, despite the "FF" value it contains!

Now for some complicating factors. Zeroing out string #3 should have erased the quad mapped by #1 according to the model I settled on last night:


But zeroing out #3 erases a DIFFERENT quad, and possibly a triangle instead. Zeroing out #2 should have erased a different quad, but *may* have erased the SAME quad #1 refers to! I have to do some more experimentation on this to confirm that the pattern of UV Map -> Polygon Pointer has been reversed in this instance. Weird!

But the moral of tonight's lesson is, whichever polygon byte string #1 is associated with, it still functions as a UV Map, despite its containing an "FF." I'm not completely comfortable with that idea, and will delve even further to get this answered in my own mind.

@Cyb: The value being a pointer makes very good sense, and that would explain it. In which case, it may be preceded by a pointer to the triangle data. I'll compare Serge's model with Kid's. If they follow the same pattern, then we've got pointers to the quad and triangle data!  And that will explain part of the purpose of Section 1-1! Yay! :D

Sora

  • Chronopolitan (+300)
  • *
  • Posts: 362
  • The Terror Of Death
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #219 on: November 27, 2007, 09:18:23 pm »
sorry, but im busy with my own chrono project ^^;;

Zeal Edit: Removed the utterly unnecessary and superfluous quoting of FW's last post.
« Last Edit: November 27, 2007, 09:24:32 pm by ZeaLitY »

justin3009

  • Fan Project Leader
  • God of War (+3000)
  • *
  • Posts: 3296
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #220 on: November 27, 2007, 10:00:26 pm »
As Zeality said.  Do you honestly expect all of this to happen right away?  3D hacking is a bitch to do hell, any hacking on PSX is harder then fuck.  I've learned that one the hard way not too long ago.  You can't expect everything just to magically be completely done in half a second..

Luminaire85

  • Guru of Time Emeritus
  • Chronopolitan (+300)
  • *
  • Posts: 311
    • View Profile
    • Chrono Cinema
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #221 on: November 27, 2007, 10:04:16 pm »
I wish I was always right. It would make things so much easier. :)

I wonder if Serge's battle model texture is meant to be 128x256. I know that in OpenGL textures must have dimensions that are exactly powers of 2. (Not really sure why.) In that case FF would be an allowed value for the V coordinates. I'm actually more worried about the ones that have an invalid U coordinate (see the UV map I posted to see those).

Wait a minute...look at 0x2658. It looks like it switches back from quads to triangles there, for 12 polys! Then at 0x26E8 it switches back to quads until 0x28E8! That's weird, and I bet that's where some of the trouble is. I'll look into that.

Thanks for removing that unnecessary quote, ZeaLitY.

Kebrel

  • Springtime of Youth
  • Magical Dreamer (+1250)
  • *
  • Posts: 1333
  • नार्य काम संस्कृत
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #222 on: November 27, 2007, 10:09:45 pm »
Before this topic gets completly back on track I want to take this time to congradulate every one involved in this it a huge undertaking and you guy are passing with flying colours. I my selfunderstand only enough to know what advanciments have been made.

At the very least Sora, these various experiments have certainly increased my own understanding of how the 3D model format works. I'm sort of an apprentice hacker here - and an apprentice can't keep asking the master for handouts. The apprentice must go through the same work to figure out the tricks of the trade, so to speak.
FaustWolf I must say I do admire your thirst to learn. But do give yourself more credit you have accompled more then many "hackers" can claim.

Luminaire85

  • Guru of Time Emeritus
  • Chronopolitan (+300)
  • *
  • Posts: 311
    • View Profile
    • Chrono Cinema
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #223 on: November 27, 2007, 10:36:19 pm »
I agree. FaustWolf, you are doing admirable work here, so kudos to you for that.

For more good news, look at the attached picture. Every extraneous U coordinate is dealt with because of the adjustment I mentioned in my last post. Not sure why there are suddenly 12 triangles in the middle (well, near the end, really) of the quad data. This may also affect the searching for headerlike information describing Section 1-2.

This also affects the non-UV "pointer" information. Thanks to that correction, the pointer data runs from -496 to +8928, with just over half of the values being negative. (Note that this is from reading the data in as signed 16-bit values, which I'm feeling more confident about with each passing post.) The correction got rid of some very negative values I was seeing, which is great.

I've also attached a text file containing all of the non-UV data converted to signed 16-bit integers, one line per triangle/quad. I don't know if anyone will see any significance in this, but here it is anyway.

[attachment deleted by admin]

justin3009

  • Fan Project Leader
  • God of War (+3000)
  • *
  • Posts: 3296
    • View Profile
Re: CHRONO CROSS FILE EXPLORATION THREAD
« Reply #224 on: November 27, 2007, 10:39:12 pm »
One thing I'd like to ask here.  What exactly is everyone trying to accomplish?  Just trying to understand CC fully so we can mess around with it like a regular CT hack?  Or just messing around with graphics possibly trying to attach other people in other poses to see what they'd look like or something.  I never really understood but I do find this work amazing.  You guys do such a great job ._.