| View previous topic :: View next topic |
| Author |
Message |
Gh0sT
Joined: 06 Jun 2006 Posts: 5
|
Posted: Tue Jun 06, 2006 2:59 am Post subject: Lua Player v0.20 Image.load issues |
|
|
Hi,
I've been using your excellent software for quite a while now and would first like to congratulate you on your great work. Without you guys the PSP homebrew scene wouldn't be as terrific as it is now! [/suckup]
Now for my question. I've coded quite a lot of small projects using v0.16 of the Lua Player soft, but as I saw all those cool new features being added I decided to upgrade to the current latest version, which is v0.20.
After trying to load up one of my homemade games I first encountered an error when I tried to require a .lua file. I fixed this by dofile-ing it.
But then the real problem came up. For some reason a regular Image = Image.load("filename.png") displays (random?) Image.load: Error loading image errors.
Do I need to load all my graphics with the new Image.loadFromMemory function or is the soft having trouble with the resolution of my .png's?
Thanks in advance and keep up the great job,
Gh0sT |
|
| Back to top |
|
 |
Shine
Joined: 03 Dec 2004 Posts: 728 Location: Germany
|
Posted: Tue Jun 06, 2006 3:40 am Post subject: Re: Lua Player v0.20 Image.load issues |
|
|
| Gh0sT wrote: | But then the real problem came up. For some reason a regular Image = Image.load("filename.png") displays (random?) Image.load: Error loading image errors.
Do I need to load all my graphics with the new Image.loadFromMemory function or is the soft having trouble with the resolution of my .png's?
|
You can use the normal load function, like the demo application Snake does without problems. If you can reproduce it with an image, I can try to fix it.
But maybe there is not enough memory, because with Lua Player 0.16 you have about 20 mb for image, programs etc. and with Lua Player 0.20 about 9 mb (try System.getFreeMemory()) . Maybe the reason is that the module loading concept needs to be improved. Meanwhile you can try to minimize your memory usage, e.g. loading only images, when you need it. |
|
| Back to top |
|
 |
romero126
Joined: 24 Dec 2005 Posts: 200
|
Posted: Tue Jun 06, 2006 4:44 am Post subject: |
|
|
| You can also free up memory by deleting the LRX files since they seem to load up into memory at the time LUAPlayer loads up, this can decrease the active memory usage. However some of your demo games may not work. Choose wisely! |
|
| Back to top |
|
 |
|