This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
I'm working on a simple game and when the game starts it preloads the following:
1. A serialized object containing a HashMap, about 8MB in size
2. About 260 png files, each one about 10-15k in size
I am running this on a 1.25Ghz G4 PowerBook and OpenJDK7 (interpreted mode) so I realize it's not going to be super fast, but it takes about three minutes before the main box appears.
I read somewhere that what I could do is put those png files into one big png file and then just chew off a part of it when necessary, and I did read that this made a substantial difference. As for the HashMap, it's basically a word dictionary. Once loaded it's quite fast, but it still takes way too long to load.
What can I do to improve performance? I should have a much faster PC (AMD Athlon X2 64 ) up and running within the next two weeks, but I will probably still need to optimize the loading.