Talk:YAZ0 (File Format)

From Custom Mario Kart
Jump to: navigation, search

YAZ0

(moved from user talk:Wiimm)

I have decided to add szs suppot to the kmp modifier but the page about the yaz0 compression isn't clear to me, can you give me a more clear explaination so I can code it myself?
kHacker35000vr 11:04, 10 November 2011 (CET)

Do you want only reading szs or also writing? Ask more detailed!
The reading example is short and fast, and in my eyes very clear. Which part can't you understand?
The writing part is more complicated, because you must try different chunks to find a good compression. See my compression source.
Use my source — why invent the wheel again?
Wiimm 16:54, 10 November 2011 (CET)
I wanted both, I didn't know that you shared the functions on a site, I can't understand the part with the chunks. Maybe an example makes it more clear.
My problem is that I use a different language and the ex. on the preview is very short.
kHacker35000vr 17:03, 10 November 2011 (CET)
I know I have nothing to do with this, but I have a friend named "MarioNumber1" who made a Yaz0 Decompression tool in C# (What kind of language is the KMP Modifier?). And you can use another program within a program. To make it easier, you can direct your program to open a Batch file, which will open Wiimm's Yaz0 decomposer. Of course, you can still use the program's source, but it is possible to use the program within a program. I can contact MarioNumber1 and see if he'll allow me to use the source (I already have the source). It's already been reversed & treated as an erray of bytes to work with endian, so it seems to be functional. I've also used some byte converters to get it to work. I will ask him, and send you the source. If you can understand C#, than you can probably re-use that source and make it compress Yaz0. I'll ask him.
SuperMario64DS, 21:58, 10 November 2011 (CET)
Let's start with decompression. I have added some comments to YAZ0#Decompression. I don't now how to be more detailed, because I think description and example are very clear (ok, I'm a programmer). Please ask more concrete.
Wiimm 15:41, 11 November 2011 (CET)
The KMP Modifier is coded in vb.net, If I read this language I can always directly understand what there stands. If I read c# it's a bit harder but I can still understand some parts. I don't need the script for decompression/compression. Maybe if I know all the commands of any compressor I can use it as extra file so I don't have to translate between 2 languages.
I do understand some parts of the YAZ0 compression, but I get stuck when I try to decrompress it myself (so no programs). Altough I'd like it more to understand it completly; if I can use (a part of) your tool as resource I can decompress and compress without more problems.
kHacker35000vr 16:14, 11 November 2011 (CET)
All my programs are .Net of course. The szs modifier's source isn't released but ctools is here: [1]. That may not be clear, but I've implemented it as a System.IO.Stream, so that it can sit transparently on top of a file stream or any other kind of stream and decompress or compress as needed. If you find that too difficult to understand (which is fair enough really), I can upload the relevant szs modifier file (it's inefficient but it does work).
Chadderz 06:50, 13 November 2011 (CET)

Special use of header offset 8

Can anyone explain the special usage of the 8 bytes (last edits). Are they really used as two 4 byte numbers? I don't believe it! And so I'll undo the last changes. -- Wiimm (talk) 20:11, 1 July 2018 (UTC)

Now you're being very selfish, and think you know everything. You have only seen files in MKW, and the article says they are 0 in MKW. The first UInt32 is used in games like BOTW and SMO. Only the first UInt32 is known, the second is always 0. In SMO, the value is always 0x1000, which is the alignment of the data inside SARC file. So the first UInt32 has something to do with the alignment of the file. Probably for the CPU to know how to align the data in memory without decompressing.

Since you're always talking about everyone is free to edit anything, then you should consider writing on the talk page first, before reverting anything, just because you don't think it's correct.
--Wexos (Talk | Contribs) – CT/MK8 Wiki Admin 20:58, 1 July 2018 (UTC)
And you are arrogant when saying "You have only seen files in MKW". How do you know that I do not know other games. And it's not the first time that you're claiming something about me that's not true.
But that is not the point. The point is the missing explanation. Now the article says: "There is a special meaning, but we don't give you any hint." And so I reverted the useless edits and started this discussion to clear this point.
-- Wiimm (talk) 21:24, 1 July 2018 (UTC)
Forgotten to explain my thoughts: The user is new and it was his first and only edit. So it was possible that he wants to troll with an incomplete info. And in this situation I think it is better to revert the edits and to discuss it with open end. -- Wiimm (talk) 21:47, 1 July 2018 (UTC)
Even if it was my first edit, that really doesn't mean anything... You could have tried and search for my name to see if I'm a troll or not. -- Aboood40091 (talk) 21:38, 10 July 2018 (UTC)
It said it was a reserved byte. There is no much more explanation to give to that (pretty much like the reserved bytes from BRFNT, which are literally documented as that in Nintendo's manuals). Also, Abood is more known in the MK8 modding community, so that's why you might not know him. —Atlas (talk) – CT/MK8 Wiki Admin 03:55, 2 July 2018 (UTC)