I'm working with a PPC and I want to load many images that are combined in a singal binary file into memory and then create surfaces from the images in memory. How do I do this? Thanks.
Loading surfaces from memory
No one ever answered my question, but I figured it out anyway. Finally got this working. If you lazy people want to know how I did it, just let me know.
Perhaps not exactly the same issue but , personally, I switched to using PhysFS which is like a virtual file system.
Basically you can create a single ( or multiple ) zip file containing all your images, data files etc and access it from your application as if this stuff was located on the filesystem.
This is a free (lgpl) software and according to the author, the design was somewhat inspired by Quake 3's file subsystem.
http://www.icculus.org/physfs/
This code compiles out of the box with VC++ - it does take a bit of tweaking to get it working with EVC ( if anyone is interested I do have a working dll/lib combo for arm arch.)
Basically you can create a single ( or multiple ) zip file containing all your images, data files etc and access it from your application as if this stuff was located on the filesystem.
This is a free (lgpl) software and according to the author, the design was somewhat inspired by Quake 3's file subsystem.
http://www.icculus.org/physfs/
This code compiles out of the box with VC++ - it does take a bit of tweaking to get it working with EVC ( if anyone is interested I do have a working dll/lib combo for arm arch.)
That is the kind of thing I want, load up all the data into a file and I only have to copy the one file over. Very similar to quake. That sounds like what I want, but the link doesn't work for me. I would like that, could you send both that and the eVC one to me, or point me to a place I can find it. Thanks.
geekyjohn@linuxmail.org
geekyjohn@linuxmail.org
You will find both X86 and ARM dll/lib files as well as physfs.h at http://www.warmi.net/pocketpc/files/Physfs_ppc.zip
More info about this library can be found at http://www.icculus.org/physfs/ ( which unfortunately seems to be down at this point but I am pretty sure it is only temporary problem since I was able to access the site couple of days ago.)
More info about this library can be found at http://www.icculus.org/physfs/ ( which unfortunately seems to be down at this point but I am pretty sure it is only temporary problem since I was able to access the site couple of days ago.)
Thanks warmi, I hope it will be back up soon.