Commit Graph

6 Commits

Author SHA1 Message Date
wagic.the.homebrew
3decbe7f1d - Fix Android compilation issues
- Added a "cachesize" option (not available from the menu, but can be manually edited in players/options.txt, for example cachesize=200 means 200MB of cache). The hardcoded cache on windows/linux is 20MB, which is not enough for Hi Res cards (60 is better, 200 is great)
2011-10-02 09:05:39 +00:00
wagic.the.homebrew
e27cf56fa2 - Support for Zip Filesystem. It is now possible to zip the entire Res folder ("store" method preferred, zip so that the root of the zip has ai, player, etc...) in one single file for read only. Write access is done in another folder (hardcoded to be User/ for now, can be updated depending on platforms, etc...
-- zipFS has several limitations...
--- in a general way, seekg doesn't work... so getting a file's size needs to be done through JFileSystem.
--- getLine on files open with zipFS doesn't work so great. Not sure if it is a normal issue because files are open in binary or not... JFileSystem therefore offers a "readIntoString" function that needs to be used instead of the usual "getline" technique. However getLine can then be used on a stream connected to the string.

-- tested on Windows and PSP, I also made sure android still works, but haven't tested zip support on Android.
-- I tried to maintain backwards compatibility, but this might break on some platforms, if I broke some platforms and you can't find a way to fix them, please contact me and we'll figure something out
-- This removes wagic::ifstream. I didn't reimplement the securities that were involved in this, apologies for that. Might be useful to reimplement such securities in JFileSystem
-- I haven't tested options/profiles in a deep way, it is possible I broke that.
2011-08-21 09:04:59 +00:00
wrenczes@gmail.com
ae227a7cb8 Minor project cleanup:
- Consolidated duplicate PSP / PSPENV defines;
- removed some ancillary file crap from the 2010 projects;
- pulled 1xx references from the makefiles;
- consolidated multiple #defines for OutputDebugString into one header (previously was split between config.h & DebugRoutines.h).
2011-04-22 13:12:36 +00:00
wrenczes@gmail.com
ec95bb93e1 Fix for a crash (I think the same one Zeth reported) where the game dies somewhere in file reading source - I wasn't paying close enough attention to the fact that there are in fact 3 separate caches, so each had their own mutex, so JFileSystem wasn't actually being protected from reentrancy. So, if the app tried to load an audio sample at the same time as an image, boom... 2011-04-20 09:03:08 +00:00
wrenczes@gmail.com
52dd0c2f91 Removed the concept of cleaning up misses from the cache, as this was causing flickering on cards whose .zip files are missing. The idea now is that, if we can't load an image, keep the cache miss around permanently so that we never redundantly make a load attempt on that file again. 2011-04-20 06:46:14 +00:00
wrenczes@gmail.com
180f83083c Fixed compilation times by refactoring: WResourceManager.h gets included either directly or indirectly into every header & cpp file; so does its includes & implementation details. Broke out WResourceManager into a pure virtual class that contains only the required calls, and added a WResourceManagerImpl header that contains all the dirty details that the rest of the app doesn't care about / need to know. 2011-04-20 06:27:44 +00:00