PAK File Creator

06 Apr 2008 13:28
Was the source code for the PAK file creator ever released ? Also I wonder how it does store the files ? (I am not a coder so I don't really have any idea how it works).


- I am asking because we're planning to adapt it for the screenshot preview option in an emulator. My impression is that loading is really fast with Beats of Rage mods on Dreamcast and the laser doesn't seem to have much to do at all, especially in comparision to some other homebrew and even many commercial games.

Quote
Senile Team Big Cheese
Avatar
06 Apr 2008 16:43
It's nothing special. It's just the data of all the files, followed by a table with the filenames, their position in the pack file and the size of each file. If Beats of Rage loads fast, I think it's mostly due to an efficient file cache.

Quote
07 Apr 2008 14:29
Standard PAK file handling isn't necessary fast, nor is it slow.  It really depends on that platform's disk performance.  The reason Dreamcast's file handling is quick is because of Neill's filecaching code.  I've modified Neill's PS2 filecaching code to be compatible with all platforms (now uses fopen/fclose/fseek instead of platform specific IO handlers) to speed up the loading times.  I remember when I ported SDL OpenBOR (locally) to Dreamcast... man was it slow because I wasn't using filecaching.  You could hear the disc and laser going nuts to load up files.


I performed some benchmarks on PSP.  Note this only applies to PSP as every platform is different in its file handling and speeds.

NonCached == 10 Minutes to load a mod.
Cached == 1 Minute to load a mod.

As you can see the benefits are great when using the slow and painful Sony MS-Duo sticks.  Well worth the 4 MBytes of ram it consumes and on PSP its using RAM from sleep mode since I'm not going to support sleep mode on OpenBOR.


Lastly, if you want the source for creating packfiles you can download it here:  link

Luigi Auriemma, was the creator of this bor pak/extractor.

Quote
02 Jun 2008 04:58
I've also noticed you have to have the pak files made with the dos pak compiler and not with quake style pak programs... if you know what i mean...

Quote
04 Jun 2008 15:06
Computica wrote:
I've also noticed you have to have the pak files made with the dos pak compiler and not with quake style pak programs... if you know what i mean...

I know what you mean. Basicly if the engine is different (Quake and BoR), the compiler must be different too.

Quote
Copyright © Senile Team. All rights reserved. | About Senile Team | Contact us
Dreamcast™ is a registered trademark of SEGA Corporation. WiiWare, Wii and the Wii logo are trademarks of Nintendo.