0
0

Hi!

What is the best format (mp3, caf, wav..) if I want fast loading and small disk space, and not too worried aabout quality? And set up, of course.

Thanks a lot for help.

  • You must to post comments
0
0

Hi riruilo,

Good question, I’ll try to be thorough so that hopefully other users find this thread useful.

In FMOD there are 3 ways to open a sound file:
[b:6vd7jiuv]Sample[/b:6vd7jiuv]
Decompress the entire sound file into memory. This is useful for very short sounds that are played often like sound effects. This will use the most memory and will take the longest to load, but will use the least CPU for playback and wont have to touch the disk at all once the sound is loaded.

[b:6vd7jiuv]Compressed Sample[/b:6vd7jiuv]
Load the whole file without decompressing it. This will take less time to load than ‘Sample’, but the trade-off is it will use more CPU decompressing the sound when it’s played.

[b:6vd7jiuv]Stream[/b:6vd7jiuv]
Only load a small chunk of the file at a time. This is good for very long sounds like music and dialog. This will have to read data from the disk quite frequently.

FMOD supports many sound formats, but regardless of what format sound file you’re using, you will always get better performance from FMOD Sound Bank (.FSB) files. (An exception to this is when using the iPhone hardware decoder which is not compatible with FSB files). To create FSB files you can use FMOD SoundBank Generator Ex tool (FSBank for short).

Here is a breif run down of the various sound formats
[b:6vd7jiuv]PCM (.wav)[/b:6vd7jiuv]
* Uncompressed
* Big on disk
* Big in memory
* No decoding required

[b:6vd7jiuv]IMA ADPCM[/b:6vd7jiuv]
* Simple compression (~3.5:1)
* Fast to decode
This is popular on low-spec devices since it has low CPU overhead.

[b:6vd7jiuv]MPEG Layer 2 (.mp2)[/b:6vd7jiuv]
* Variable compression quality
* Small on disk
* Greater CPU

[b:6vd7jiuv]MPEG Layer 3 (.mp3)[/b:6vd7jiuv]
* Variable compression quality
* Better than quality than MP2
* Decoding uses more CPU than MP2
* Requires licensing [i:6vd7jiuv]- this license may be included when using the hardware decoder but you would have to make sure.[/i:6vd7jiuv]

For a low spec device such as iPhone, I would recommend as a starting point:
Sound Effects: IMA ADPCM encoded FSB loaded as Sample or Compressed Sample
Music/Dialog: MP3 using iphone hardware decoder

  • You must to post comments
0
0

Thanks. I didn’t know about Compressed Samples.

What do you think about CAF? I have seen that file format in several games.
Where in your list should it be placed?

Thanks, really useful.

  • You must to post comments
0
0

Checkout the Development Version: 4.31.03. There have been some updates to fmodex.chm. Look in "Notes on Performance" in the iPhone section of "Platform Specific Issues."

  • You must to post comments
Showing 3 results
Your Answer

Please first to submit.