Search code examples
iosios4audiopackaging

What is the best way for packing 6000+ sound files in a iOS Application


I'm working on a iOS application that will contain around ~6000 mp3 of sounds files. Each one is around 1 second (2 max) long and rather low quality (24K bitrate) weighting in at around 2-3KB each. (Please do not comment on the quality, it's as it should be)

Since this is a large amount of files I was wondering what we be the best approach for packing these into the bundle? Should I just throw them together in a group? Is there someway of storing them in a single "package" file then reading them out separately as needed?

Also, what would be the best place to place them: Library/ ? Documents/?

As I'm rather new to iOS development and kick in the right direction will be greatly appreciated.

Thanks in advance, Ken.


Solution

  • You can create a bundle which will contain all your mp3 files. Your files will be in the ressources of your application, no need to store them in the Documents or Library path of your application sandbox.

    The way to create and access a bundle is illustrated here.

    Hope this helps