Quote:
Originally Posted by FitGirl
There is a heavy chance that the extractor you use for DAT is actually not simply extracting wav files, but converts them from something like ADPCM encryped wavs to simple PCM wavs, hence the inflated size after final compressor. ADPCM was pretty popular in Mafia 1 times.
And thanks for pointing to bzip3, will include it into my bruteforcing queue.
|
Disagree...
What would be the point of a lossy algorithm in this game? Apart from WAV files, there is no other format, besides the trio of OGG and BMP/JPG and TGA/others, to create lossy compressed files from the original source files for storage in these *.dta archives. There are many file types that, if they could be lossily decompressed from these *.dta archives, would only cause problems.
Based on this code snippet, it is most likely a lossless compression method that is highly optimized for WAVs. (WAV Deltas+LZSS/RLE+other and crypting)
See this code:
https://github.com/DavoSK/OpenMF/blo...dta/parser.hpp
UPD: I can also imagine that WAV files go through some kind of LossyWAV-like data filtering before being compressed into a *.dta archive, but that still wouldn't explain the strange results that classic audio compressors are humiliated with a 20-45% better (final) compression ratio. (*.dta vs. unpacked+MSC or *.dta.7z vs. Unpacked+MSC)
I've already encountered something like this on a 24bit/48kHz WAV file set, where LOLZ beat TAK by 20+%, but with two-step lossless compression, the final compression ratio was almost 40% better than the default. The case very RARE.
Example:
Source: ~1950MB
ALAC: 990MB
TAK: ~850MB
WAVPACK: 800MB
Razor: 735MB
LOLZ: 681MB
ALAC+7z: 478MB
ALAC+Bliz: 439MB
What is the reason for the results? Dithering? Channel deduplications? Any???
UPD2: Obviously, with a simple test, we could finally verify whether the algorithm/archive format is lossy or lossless in many file types, if the "DTAs Packer" linked on the previous page were willing to compressing WAV or other files of any size (ex: enwik8, any.tga/bmp, music.mp3) into a new DTA archive and compare it with the original files after unpacking it. In the case of WAVs, it is questionable how many formats are supported in the range of mono/stereo, 8-48kHz and 4-32bit.
Furthermore, if there were a simple decryptor for *.dta files, which would only decrypt the encryption (similar to adftool/stream_tool, ue3/4 keys methodology, etc...), would the game run with these files in their unencrypted form?? In principle, the final compression could also be improved. (cca. 0.1% upto small percentage??)
example: dta_decrypt.exe A0.dta A0_decrypted.dta <key1> <key2>